Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 21
Default vlookup Variables

I download a new spreadsheet everyday, this spreadsheet will have several new
rows everytime.

What I need is for this lookup to automatically find the last row in the
table array

Range("H2").Select
ActiveCell.FormulaR1C1 = _
"=VLOOKUP(RC[8],'[Cell Refs Update Macro
V3.xls]Lookup'!R2C1:R1770C5,3,FALSE)"
Selection.AutoFill Destination:=Range("H2:H" & lastrow)

Can anybody help me?

  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 186
Default vlookup Variables

Hi,
One way:

LastRow=Range("A65536").End(xlUp).Row

(Assuming that column A has data in the last row.)

--
Ken Hudson


"Megadrone" wrote:

I download a new spreadsheet everyday, this spreadsheet will have several new
rows everytime.

What I need is for this lookup to automatically find the last row in the
table array

Range("H2").Select
ActiveCell.FormulaR1C1 = _
"=VLOOKUP(RC[8],'[Cell Refs Update Macro
V3.xls]Lookup'!R2C1:R1770C5,3,FALSE)"
Selection.AutoFill Destination:=Range("H2:H" & lastrow)

Can anybody help me?

  #3   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 35,218
Default vlookup Variables

Remember to check your other post(s).

Megadrone wrote:

I download a new spreadsheet everyday, this spreadsheet will have several new
rows everytime.

What I need is for this lookup to automatically find the last row in the
table array

Range("H2").Select
ActiveCell.FormulaR1C1 = _
"=VLOOKUP(RC[8],'[Cell Refs Update Macro
V3.xls]Lookup'!R2C1:R1770C5,3,FALSE)"
Selection.AutoFill Destination:=Range("H2:H" & lastrow)

Can anybody help me?


--

Dave Peterson
Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
VLookup a Vlookup adamb2000 Excel Worksheet Functions 4 June 28th 06 10:54 PM
VLOOKUP Problem Ian Excel Discussion (Misc queries) 3 April 6th 06 06:47 PM
Please Help! vlookup & match with multiple variables ivygirl Excel Worksheet Functions 2 January 7th 06 10:46 AM
VLOOKUP Limitations chris_manning Excel Worksheet Functions 2 August 9th 05 06:23 PM
vlookup data hidden within worksheet Excel Worksheet Functions 0 January 26th 05 01:09 PM


All times are GMT +1. The time now is 09:37 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"