|  
                                             
	Guten Tag Allerseits 
	Ich wäre froh könnte mir jemand helfen diesen code in eine while Schlaufe umzuschreiben (falls das überhaupt geht). 
	Zur Info, bin blutiger Anfänger. 
	Hier der Code: 
	  
	If AnfangMBSTJahr <> "" Then 
	 
	If AnfangMBSTJahr = "2" Then 
	 
	'MsgBox ("2016") 
	 
	If AnfangMBST = "2" Then 
	Cells(Cells(Rows.count, "A").End(xlUp).Row + 0, "A").Offset(-1, 1).Interior.Color = RGB(5, 70, 150) 
	Cells(Cells(Rows.count, "A").End(xlUp).Row + 0, "A").Offset(-1, 1).Select 
	End If 
	 
	 
	If AnfangMBST = "3" Then 
	Cells(Cells(Rows.count, "A").End(xlUp).Row + 0, "A").Offset(-1, 2).Interior.Color = RGB(5, 70, 150) 
	Cells(Cells(Rows.count, "A").End(xlUp).Row + 0, "A").Offset(-1, 2).Select 
	End If 
	 
	If AnfangMBST = "4" Then 
	Cells(Cells(Rows.count, "A").End(xlUp).Row + 0, "A").Offset(-1, 3).Interior.Color = RGB(5, 70, 150) 
	Cells(Cells(Rows.count, "A").End(xlUp).Row + 0, "A").Offset(-1, 3).Select 
	End If 
	 
	 
	If AnfangMBST = "5" Then 
	Cells(Cells(Rows.count, "A").End(xlUp).Row + 0, "A").Offset(-1, 4).Interior.Color = RGB(5, 70, 150) 
	Cells(Cells(Rows.count, "A").End(xlUp).Row + 0, "A").Offset(-1, 4).Select 
	End If 
	 
	 
	If AnfangMBST = "6" Then 
	Cells(Cells(Rows.count, "A").End(xlUp).Row + 0, "A").Offset(-1, 5).Interior.Color = RGB(5, 70, 150) 
	Cells(Cells(Rows.count, "A").End(xlUp).Row + 0, "A").Offset(-1, 5).Select 
	End If 
	 
	 
	If AnfangMBST = "7" Then 
	Cells(Cells(Rows.count, "A").End(xlUp).Row + 0, "A").Offset(-1, 6).Interior.Color = RGB(5, 70, 150) 
	Cells(Cells(Rows.count, "A").End(xlUp).Row + 0, "A").Offset(-1, 6).Select 
	End If 
	 
	If AnfangMBST = "8" Then 
	Cells(Cells(Rows.count, "A").End(xlUp).Row + 0, "A").Offset(-1, 7).Interior.Color = RGB(5, 70, 150) 
	Cells(Cells(Rows.count, "A").End(xlUp).Row + 0, "A").Offset(-1, 7).Select 
	End If 
	 
	If AnfangMBST = "9" Then 
	Cells(Cells(Rows.count, "A").End(xlUp).Row + 0, "A").Offset(-1, 8).Interior.Color = RGB(5, 70, 150) 
	Cells(Cells(Rows.count, "A").End(xlUp).Row + 0, "A").Offset(-1, 8).Select 
	End If 
	 
	If AnfangMBST = "10" Then 
	Cells(Cells(Rows.count, "A").End(xlUp).Row + 0, "A").Offset(-1, 9).Interior.Color = RGB(5, 70, 150) 
	Cells(Cells(Rows.count, "A").End(xlUp).Row + 0, "A").Offset(-1, 9).Select 
	End If 
	 
	If AnfangMBST = "11" Then 
	Cells(Cells(Rows.count, "A").End(xlUp).Row + 0, "A").Offset(-1, 10).Interior.Color = RGB(5, 70, 150) 
	Cells(Cells(Rows.count, "A").End(xlUp).Row + 0, "A").Offset(-1, 10).Select 
	End If 
	 
	If AnfangMBST = "12" Then 
	Cells(Cells(Rows.count, "A").End(xlUp).Row + 0, "A").Offset(-1, 11).Interior.Color = RGB(5, 70, 150) 
	Cells(Cells(Rows.count, "A").End(xlUp).Row + 0, "A").Offset(-1, 11).Select 
	End If 
	 
	If AnfangMBST = "13" Then 
	Cells(Cells(Rows.count, "A").End(xlUp).Row + 0, "A").Offset(-1, 12).Interior.Color = RGB(5, 70, 150) 
	Cells(Cells(Rows.count, "A").End(xlUp).Row + 0, "A").Offset(-1, 12).Select 
	End If 
	 
	End If 
     |