Hi,
I'm running this line (from longer code of course), where i/g are integers and h is a range:
And I'm getting run time error '1004'. Any idea why?![]()
Please Login or Register to view this content.
Hi,
I'm running this line (from longer code of course), where i/g are integers and h is a range:
And I'm getting run time error '1004'. Any idea why?![]()
Please Login or Register to view this content.
Please * if you like the answer
Probably just means that g isn't found in the range h.
Regards, TMS
Trevor Shuttleworth - Retired Excel/VBA Consultant
I dream of a better world where chickens can cross the road without having their motives questioned
'Being unapologetic means never having to say you're sorry' John Cooper Clarke
TMS, I see that you're right because when I'm searching g manually in h it is not found AS IS. This is because g=410 (in sheet x) while in h (in sheet y) it is written as 410.1. How would you solve this problem? BTW - replacing FALSE with TRUE in the vlookup function didn't help..
Dunno. That's a different question altogether.How would you solve this problem?
I would suggest that you upload a sample workbook with some typical data, ideally in a new thread (having marked this one as solved.
Regards, TMS
Yes, sure. A bit later I'll come back to it through a new thread.
You can try with .find:![]()
Please Login or Register to view this content.
.. and don't forget to have fun!
Bogdan.
mark SOLVED andAdd Reputation if my answer pleases you
bulina, what does the integer I'm receiving represent?
Because you declared i as an integer, my guess is that i is the integer part of 410.1. (the found number). If you declare it string it will bring the whole 410.1 string.
This is a progress. i returns now 410.1 exactly as in range h. However the "Unable to get the Vlookup property of the WorksheetFunction class" message remains intact![]()
Just to update that when I use vlookup manually to check things, it returns N/A which is the equivalent of VBA's message mentioned above. It's weird, and it's not a VBA prob., it's basic than that.
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks