Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Relative path to tables?
Message
From
04/10/2006 13:28:53
 
 
To
All
General information
Forum:
Visual FoxPro
Category:
Databases,Tables, Views, Indexing and SQL syntax
Title:
Relative path to tables?
Miscellaneous
Thread ID:
01159453
Message ID:
01159453
Views:
64
Hi there!

I have an app I've been working on for a little over 1 year. During that time, I distributed several versions of the app (using InstallShield Express 6, then X) whether by releading a full install package, or just a patch upgrade.

I made some changes in the app to answers my clients' needs and am ready to distribute/deploy a new version. The problem I get si that VFP seems to keep a relative path to my tables in the DBC (never been a problem before!). If I build the app from the pproject manager and then run it, it works fine whether VFP9 dev environment is running or not.

If I then produce an installer of the project using InstallShield X, I get file no found error messages from my app when I run it telling me that it cannot find some table in the same relative path as it would expect it to be if I was on my development machine


Example:
In my office, I'm working in d:\workplace\VFP\AppName\, and my DB (AppName.dbc) is in d:\workplace\VFP\AppName_BD\

In the deploy scenario, the app will deploy in c:\program files\AppName\, with the DB in c:\program files\AppName\BD\.

So when I run the newly installed program, it crashes at the startup because it's trying to initialize income tax rates from a table in my DBC, but looks for the table in c:\program files\AppName_BD\, thus using the same relative path from the main EXE to the tables folder as in my development environment.

Problem is: I never asked nor used a relative path in my definitions. It can't the database that can't be found because it's found in a procedure before initializing those values, and wouldn't allow the app to start if it didn't succesfully opened the DB. The paths (set path to) are set in the same procedure as the one that finds the DB, and are populated from an ini file that is being filled by my installation routine (I've checked it after installation and the paths are in there all right...)

Anyone has clue as to what may be happening? Please remember that I've released numerous version of that app with the same tools and that is the first time I get that strange behavior. I've also tried validate database (with and without the recover clause) both on my development databasee, and on the one that gets installed, to no avail...

I'm in some sort of a hurry as I already told my clients everything was OK and the new CDs would be shipped soon. Any help is appreciated!

Regards,
Pascal Marier-Dionne
Québec, Canada
Next
Reply
Map
View

Click here to load this message in the networking platform