Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Trapping LOCATE DB Error
Message
From
22/02/1999 19:58:46
Ian Matthews
Up & Running Technologies Inc
Chestermere, Alberta, Canada
 
 
To
22/02/1999 19:38:28
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
00190235
Message ID:
00190261
Views:
24
I have done that for previous apps but it requires the machine to have VFP or some DBF editor on their machine. I install most of my apps myself and want a quit way to change the path without having to use anything more than NOTEPAD.

I just found a note about using DEFAULT= "your path here" in the CONFIG.FPW and now have that working.


I am still stuck on trapping LOCATE DB ERROR. If a DB or table is not in the specified PATH (or more usually, the PATH is bad) VFP must have some way to trap the resulting message before it appears. I checked error codes 1105,1554,1736 but as I mentioned previously, my ERROR HANDLER procedure is not being invoked at all. VFP must consider this more of a notification than an error.



>Ian,
>
>What I usually do is have a stand-alone 'system' table with one single record.
>
>In there I keep some system wide information (like the data path) and then
>load these system-wide parameters in public variables at startup.
>
>This way you can store your path or other system-wide parameters outside
>your code.
>
>This has helped me in some applications where users had to install
>the application locally but with the data in some remote data storage
>localtion. Since each user had the possibility to mount the data storage
>location on different network drives or even through RAS I
>created a secondary application that let them change the path value
>in the table.
>
>HTH
>
>Pascal
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform