Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 23
Default worksheetfunction

I get an error on this code:

LOEcriteria = Application.WorkSheetFunction.Vlookup(K4,'WBS
Code'!$A$2,$$d$40,4,0)

The error message highlights the single quote at 'WBS Code'

What do I need to do?

GMet


  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 5,441
Default worksheetfunction

Glen,

Change

Application.WorkSheetFunction.Vlookup(K4,'WBS Code'!$A$2,$$d$40,4,0)

to

Application.WorkSheetFunction.Vlookup(Range("K4".V alue,Worksheets("WBS
Code").Range("$A$2,$$d$40"),4,0)

HTH,
Bernie
MS Excel MVP

"GMet" wrote in message
...
I get an error on this code:

LOEcriteria = Application.WorkSheetFunction.Vlookup(K4,'WBS
Code'!$A$2,$$d$40,4,0)

The error message highlights the single quote at 'WBS Code'

What do I need to do?

GMet




  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 5,441
Default worksheetfunction

Arrrrrrgggg...

Forgot to close my parens.... and I didn't see your comma instead of a
colon in the second range....

Application.WorkSheetFunction.Vlookup(Range("K4"). Value,Worksheets("WBS
Code").Range("$A$2:$$d$40"),4,0)

HTH,
Bernie
MS Excel MVP

"Bernie Deitrick" <deitbe @ consumer dot org wrote in message
...
Glen,

Change

Application.WorkSheetFunction.Vlookup(K4,'WBS Code'!$A$2,$$d$40,4,0)

to

Application.WorkSheetFunction.Vlookup(Range("K4".V alue,Worksheets("WBS
Code").Range("$A$2,$$d$40"),4,0)

HTH,
Bernie
MS Excel MVP

"GMet" wrote in message
...
I get an error on this code:

LOEcriteria = Application.WorkSheetFunction.Vlookup(K4,'WBS
Code'!$A$2,$$d$40,4,0)

The error message highlights the single quote at 'WBS Code'

What do I need to do?

GMet






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
Can't use WorksheetFunction Yossi Excel Discussion (Misc queries) 5 January 25th 06 10:07 PM
WorkSheetFunction.CountIf & WorkSheetFunction.SumIf with 2 conditions? Etien[_2_] Excel Programming 3 January 13th 04 04:07 PM
WorksheetFunction Mike Fogleman Excel Programming 2 January 1st 04 11:17 PM
WorksheetFunction Stuart[_10_] Excel Programming 3 November 13th 03 12:33 AM
worksheetfunction devnext Excel Programming 1 October 29th 03 12:48 PM


All times are GMT +1. The time now is 07:54 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"