Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Return statements within the with endwith blocks
Message
From
06/01/2017 16:59:08
 
General information
Forum:
Visual FoxPro
Category:
Troubleshooting
Environment versions
Visual FoxPro:
VFP 9 SP2
OS:
Windows 10
Database:
MS SQL Server
Miscellaneous
Thread ID:
01646361
Message ID:
01646374
Views:
43
This message has been marked as a message which has helped to the initial question of the thread.
I know about the use of RETURN inside of WITH - ENDWITH; I am skeptical that this is your true cause. I have this code construct in many places and never had any crashes and my current application has been running in production for over 3 years (I have older ones that date back 10 years with no crashes reported). You said in your first post that this was occurring during pasting into an OCX control from the clipboard. How is this related to the RETURN within a WITH - ENDWITH? Is the crash occurring immediate on the copy-n-paste or when the user is trying to save or do something else? Where is the C5 originating from (what method). You could spend a lot of time changing all the WITH - ENDWITH coding to only find the problem is still present.

I have found that many times during a copy-n-paste from other sources there can be many control codes embedded into the string being pasted. The fix was to first 'scrub' the string of invalid characters before pasting; i.e. ASCII codes 0-31 (except TAB, CR, and LF) and any codes above 132. This might be the true culprit.
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform