LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 65
Default another Vlookup question

I've searched through the archives about using
worksheetfunction.Vlookup in VBA, but I'm getting an error I haven't
seen before.

I'm running Excel 2003. My routine takes a large data base, reduces
the data into an A x B table, then uses the data in the table against
a B x C table. For diagnostics and ease of following the math, both
arrays are written to a temporary worksheet and given range names.

So, my code loops though one of the named ranges, does the lookup,
then sums the result into a final array:

deptArray(i,j)=deptArray(i,j) + WorksheetFunction.VLookup
(ActiveCell.Offset(j,0), "RangeName1", k, False)

where i,j are the array bounds, RangeName1 is the named range of one
of the arrays, k is the column number of the value to return, and
activecell is the upper leftmost corner of the second named range.

The error I get is :

Runtime error '1004'

Unable to get the VLookup property of the
WorksheetFunction Class

I've got all the standard add-ins on the Excel side running, and no
available add-ins on the VBA side.

Any suggestions?

Art
 
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 Question Annie Excel Worksheet Functions 1 February 6th 10 11:00 PM
Another Vlookup for VBA question petedacook Excel Programming 4 July 22nd 09 03:21 PM
Vlookup Question Ewing25 Excel Programming 1 May 6th 08 03:16 PM
IF/AND VLOOKUP question... Kevin Excel Discussion (Misc queries) 3 December 16th 07 10:41 PM
Vlookup question mpenkala Excel Discussion (Misc queries) 4 December 13th 07 05:54 PM


All times are GMT +1. The time now is 09:32 AM.

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

About Us

"It's about Microsoft Excel"