Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Move my database, tables and forms refference old locati
Message
De
15/03/2001 17:38:03
Dragan Nedeljkovich (En ligne)
Now officially retired
Zrenjanin, Serbia
 
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Autre
Divers
Thread ID:
00485388
Message ID:
00485647
Vues:
17
>This may seem like a stupid Visual Foxpro question but I created a database with classes,tables, forms and menu. It works fine but I would like to modify it. If I copy it from my network drive and put it on my c: drive how do I tell it that it has a new location. Somewhere in the DBC it is keeping track of the location of where it was created. All the tables and programs are pointing to the network. How can I change my test Project and DBC to point to the new location and forget all about where it use to live? When I go to run a program that opens up my forms it opens the forms on the server, not my c: drive. Any ideas, this is driving me nuts.

Two ways out of this:
1 - hide the source drive. If your original tables are on the z: drive, unmap the Z: drive. This way is OK, and your app will work - it does store them with relative paths anyway, but compiles them with full paths, and uses these full paths if available. If not, it uses the relative paths. No, no theoretical background here - just been there, done that.
2 - add some code to your .dataenvironment.beforeopentables, which will set the data paths straight. You can set the locations of your tables relative to whatever you like before they get actually opened. I've actually written some generic code which I call like this: oApp.SetDataPaths(this), i.e. I'm passing the dataenvironment as a parameter to it.

If you need a sample of this piece of code, just tell me. It may be proprietary to the company where I work, so I'd have to strip the details.

back to same old

the first online autobiography, unfinished by design
What, me reckless? I'm full of recks!
Balkans, eh? Count them.
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform