Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 35,218
Default Best practice in qualifying Excel worksheet function invocation

I'd guess that you did something wrong if iserror() didn't return an error when
there was no match. But since you didn't share any details, I don't have a
guess.

And using ...worksheetfunction.vlookup() won't return a value if there's not a
match. That was the second example in my earlier post.




wrote:

Dave, I tried the iserror function on the variable in which I stuck
the VLookup return value. IsError never becomes true when VLookup
fails to find something. I resorted to using the Err object as
described at
http://www.cpearson.com/excel/Callin...ionsInVBA.aspx.

It turns out that if there is an error, the left-hand-side does not
actually get a result.

I suuppose I could always try putting the VLookup expression inside
IsError as an argument, but then I'd have to repeat that expression to
assign to the destination variable when IsError evaluates to False.

Anyway, I'm sure this is motherhood to most, but it feels like I'm
finally starting to "operate" in the VBA environment.

Thanks again for the leads.


--

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
How to use ADOX on Excel? How to automate Excel invocation on existing xls file from vbs? Siegfried Heintze Excel Programming 0 June 7th 08 08:03 PM
Qualifying Commandbars - Excel 2000 Victor[_5_] Excel Programming 2 February 20th 06 09:13 PM
SQL practice with Excel? J_J[_2_] Excel Programming 4 September 25th 05 05:55 AM
Macro invocation after data enrtry josh Excel Programming 3 June 11th 04 05:57 PM
Automatic Macros Invocation pthien Excel Programming 5 August 6th 03 05:52 PM


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