ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   VBA and use vlookup from one sheet to copy data from another sheet (https://www.excelbanter.com/excel-programming/369854-vba-use-vlookup-one-sheet-copy-data-another-sheet.html)

sverre

VBA and use vlookup from one sheet to copy data from another sheet
 
Hi

'in below "do while macro" I would like to find/use the value in cell (x,3)
in activesheet and goto next sheet x 2 'and find the same value which is
stored in column 1 and from that row copy value in column 7 'which I then use
i prev sheet x 2 and insert in cells (x, 6)

'Do I use some kind of vlookup?

--------------------------------------------------
Sub Hämta_instrumentnamn()

Sheets("makro").Activate

ActiveSheet.Previous.Select

x = 5

Do While Cells(x, 3).Value < ""

Cells(x, 3).Value.Copy





x = x + 1

Loop


End Sub



All times are GMT +1. The time now is 01:18 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com