1 year ago
#345689
user18609963
How to make an Loop until there is No value in Cell
Hey i want to check if a cell has a value and if so take the values to another , File and replace them If matched. Then go back the the list and go one cell down an repeat until there ist no more value in the list. I am Stuck at the while Point. Sorry for my Bad english...
Sub Refresh()
Set pullData = ActiveWorkbook
Dim A as String
Dim B as String
Dim C as String
Dim i as Integer
i = 1
While IsEmpty(Cells(i, 1).Value) = False then
A = Cells(i, 1)
B = Cells(i, 2)
C = Cells(i, 3)
ThisWorkbook.Activate
Sheets("DaysOfOpsPlan").Select
LZ = Cells(Rows.Count, 1).Ende(xlUp).Roes.Row
For t = LZ To 2 Step -1
If Cells(t, 1).Value = A then
Cells(t, 1).Value = A
Cells(t, 2).Value = B
Cells(t, 3).Value = C
i = i + 1
```
excel
vba
loops
if-statement
basic
0 Answers
Your Answer