Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Retrieving File Name if File Access Error Occurs
Message
From
29/05/2001 14:09:15
 
 
To
29/05/2001 14:04:51
General information
Forum:
Visual FoxPro
Category:
Troubleshooting
Miscellaneous
Thread ID:
00512287
Message ID:
00512335
Views:
9
This message has been marked as a message which has helped to the initial question of the thread.
>>Sharing of network files can cause "File access denied" errors. I am trying to write an error handling procedure and want to return the name of the file that cannot be accessed.
>>
>>I could use MESSAGE(1) to provide code line information and parse out a name, but it would fall short if macro-substitution was used.
>>
>>Does FoxPro or Windows provide anything I could use?

Let's try that again.

One way might be to create a property of a global application object (or a PUBLIC variable) like oApp.cFileBeingOpened. Just prior to actually trying to access a file, set its value appropriately. Since it's global, you should be able to access it from your error handler if necessary.
Regards. Al

"Violence is the last refuge of the incompetent." -- Isaac Asimov
"Never let your sense of morals prevent you from doing what is right." -- Isaac Asimov

Neither a despot, nor a doormat, be

Every app wants to be a database app when it grows up
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform