C
cstang
Pls help me to change to a proper code.. it looks ugly.
sub Test ()
Dim a As Integer
a = 11
Do Until Cells(a, 2) = Empty
Cells(a, 3) = Application.VLookup(Cells(a, 2),
Sheets("RuWet").Range("IndonWet"), 2, 0)
Cells(a, 4) = Application.VLookup(Cells(a, 2),
Sheets("RuWet").Range("IndonWet"), 3, 0)
Cells(a, 5) = Application.VLookup(Cells(a, 2),
Sheets("RuWet").Range("IndonWet"), 4, 0)
Cells(a, 6) = Application.VLookup(Cells(a, 2),
Sheets("RuWet").Range("IndonWet"), 5, 0)
Cells(a, 7) = Application.VLookup(Cells(a, 2),
Sheets("RuWet").Range("IndonWet"), 6, 0)
Cells(a, 8) = Application.VLookup(Cells(a, 2),
Sheets("RuWet").Range("IndonWet"), 7, 0)
Cells(a, 9) = Application.VLookup(Cells(a, 2),
Sheets("RuWet").Range("IndonWet"), 8, 0)
Cells(a, 10) = Application.VLookup(Cells(a, 2),
Sheets("RuWet").Range("IndonWet"), 9, 0)
a = a + 1
Loop
end sub
Thank you
Cstang
sub Test ()
Dim a As Integer
a = 11
Do Until Cells(a, 2) = Empty
Cells(a, 3) = Application.VLookup(Cells(a, 2),
Sheets("RuWet").Range("IndonWet"), 2, 0)
Cells(a, 4) = Application.VLookup(Cells(a, 2),
Sheets("RuWet").Range("IndonWet"), 3, 0)
Cells(a, 5) = Application.VLookup(Cells(a, 2),
Sheets("RuWet").Range("IndonWet"), 4, 0)
Cells(a, 6) = Application.VLookup(Cells(a, 2),
Sheets("RuWet").Range("IndonWet"), 5, 0)
Cells(a, 7) = Application.VLookup(Cells(a, 2),
Sheets("RuWet").Range("IndonWet"), 6, 0)
Cells(a, 8) = Application.VLookup(Cells(a, 2),
Sheets("RuWet").Range("IndonWet"), 7, 0)
Cells(a, 9) = Application.VLookup(Cells(a, 2),
Sheets("RuWet").Range("IndonWet"), 8, 0)
Cells(a, 10) = Application.VLookup(Cells(a, 2),
Sheets("RuWet").Range("IndonWet"), 9, 0)
a = a + 1
Loop
end sub
Thank you
Cstang