Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Paths & drive letter referencing over network applicatio
Message
From
14/04/1998 14:12:37
 
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
00091853
Message ID:
00091855
Views:
22
>Hi there,
>I have a simple windows 95 peer to peer network of about 8 computers.
>
>In my last fpw2.6 application, all my files making up the application were dumped together in one directory/folder. Other computers on the network could access this application by simply mapping a drive letter (D: or E: or F: etc) to this folder, and then running the application.
>
>Now I have done things the 'correct' way and have my various files separated into subdirectories such as "data","menus","forms" etc.
>However, I have now had to use path referencing such as "do form c:\app\forms\form1.scx". This now causes problems for other computers on the network, because it looks for these files on their c: drives.
>
>I have tried changing the path to \\computername\app\forms\form1.scx but then I get an error: 'file already in use' on my computer.
>
>What I have done so far is to place the following in my 'startup' program:
>
>store sys(5) to mcDrive && store that computers mapped drive letter
> if sys(5) = "c:" && and it is my computer
> store "c:\app" to mcDrive && include this only for my computer
> endif
>
>Then I have changed paths to include the &mcDrive as follows:
>
>do form &mcDrive\forms\form1.scx
>
>Is this the best way of getting around this path problem? Any suggestions?


Looks good to me...the old theory "if it works, it must be good".

In your PATH statements within the app, ensure you use relative path addressing, such as SET PATH TO "..\data\"
------------------------------------------------
John Koziol, ex-MVP, ex-MS, ex-FoxTeam. Just call me "X"
"When the going gets weird, the weird turn pro" - Hunter Thompson (Gonzo) RIP 2/19/05
Previous
Reply
Map
View

Click here to load this message in the networking platform