No, with the Cstr and Nz it doesn't crash anymore, but there's no calculations being done with those values, it's just pulling the data and displaying it, nothing else.
No, with the Cstr and Nz it doesn't crash anymore, but there's no calculations being done with those values, it's just pulling the data and displaying it, nothing else.
I tested the DLookup by creating record in tbl_Best_Months with a 0 in BestMonth field. I removed the CStr functions. This results in #Type! error in the textbox but no crash. The error is because of + operator. Switching to & character for concatenation fixes that. Sorry, can't replicate the crash.
How to attach file: http://www.accessforums.net/showthread.php?t=70301 To provide db: copy, remove confidential data, run compact & repair, zip w/Windows Compression.
With the CStr and Nz added to the expression it stopped crashing but if there were any subsequent calculations done they would fail because of the CStr. Very strange.
It's also very strange that I don't get the crash.
How to attach file: http://www.accessforums.net/showthread.php?t=70301 To provide db: copy, remove confidential data, run compact & repair, zip w/Windows Compression.
I have about 30 users who use this database, they all experience the error and I get it on my test machine, too.
Maybe a 64-bit issue?
How to attach file: http://www.accessforums.net/showthread.php?t=70301 To provide db: copy, remove confidential data, run compact & repair, zip w/Windows Compression.
Oooooo. Good call. We're all 64-bit. I'll have to test that. Thanks so much.
My 8-yr old HP laptop does not crash with CStr removed from the original DLookup expression. Just the #Type! error displays as result in textbox. Good luck.
How to attach file: http://www.accessforums.net/showthread.php?t=70301 To provide db: copy, remove confidential data, run compact & repair, zip w/Windows Compression.