Warum wird hier eine Endlosschleife erzeugt?
10.05.2006 16:51:39
Björn
Private Sub Worksheet_Change(ByVal Target As Range)
With ThisWorkbook.ActiveSheet
Dim inty As Integer
Dim intz As Integer
inty = 1
Do Until .Cells(33, inty) = "0"
inty = inty + 1
Loop
intz = inty - 1
.Cells(40, 4) = .Cells(35, intz)
.Cells(40, 2) = "Kapitalwert nach " & .Cells(32, intz) & " Jahren:"
End With
End Sub
Wenn ich von folgenden Zeilen immer nur eine nehme, dann funktioniert es, mit beiden läuft sich die Schleife tot ?
.Cells(40, 4) = .Cells(35, intz)
.Cells(40, 2) = "Kapitalwert nach " & .Cells(32, intz) & " Jahren:"