hi!
have code that's something like:
Please Login or Register to view this content.
works for a bit and they says, invalid use of null... why is this happening, why does this not trigger the error handler?
hi!
have code that's something like:
Please Login or Register to view this content.
works for a bit and they says, invalid use of null... why is this happening, why does this not trigger the error handler?
I'd suggest a quick read through of: http://www.cpearson.com/excel/ErrorHandling.htm
trust me - it's worth it - understanding error handling is important.
My Recommended Reading:
Volatility
Sumproduct & Arrays
Pivot Intro
Email from XL - VBA & Outlook VBA
Function Dictionary & Function Translations
Dynamic Named Ranges
Ok, read through that. as a matter of fact i'd seen it before but re-read to see if i missed something, i'm afraid i still can't see why it does not work... it seems to operate correctly for the first error but not the second... very odd
To quote from the link:
I think that pretty much covers it, no ?Originally Posted by Chip Pearson
Once you invoke the handler unless you Exit or use a Resume Statement you remain within the Handler... it follows that if a subsequent error occurs then there is no error handler (you're already in it).
Last edited by DonkeyOte; 10-22-2010 at 05:59 AM. Reason: added final sentence
aaaaah i see, i was confused about remaining inside the handler..
so i should have my error handler outside of the loop and then use a resume label to return to the loop at the desired point. i shall go work on this
thanks for your assistance
Jonathan
Even better to just test for rst.eof before you attempt to read the record. If true, there's no record to read.
Remember what the dormouse said
Feed your head
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks