I wanted to copy I,K,M,O,Q and S column in each row into another sheet.
Initially, I have written the code to copy my data into another sheet as the following:
xlsheet_l.cells(4,6) = xlsheet.cells(5,9)
xlsheet_l.cells(4,7) = xlsheet.cells(5,11)
xlsheet_.cells(4,8) = xlsheet.cells(5,13)
xlsheet_.cells(4,9) = xlsheet.cells(5,15)
xlsheet_l.cells(5,6) = xlsheet.cells(6,9)
xlsheet_l.cells(5,7) = xlsheet.cells(6,11)
xlsheet_.cells(5,8) = xlsheet.cells(6,13)
xlsheet_.cells(5,9) = xlsheet.cells(6,15)
However, I have over 500 rows to copy my data into another sheet. I want to shorten my code.Therefore, I have tried on the looping. Is there anyway that I can shorten my code?
Bookmarks