Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

VFP not seeing Network Storage on Boot Up

Status
Not open for further replies.

David Higgs

Programmer
May 6, 2012
392
GB
I have my "VFP Projects" located on a Networked Drive so that I can access my projects from either my Laptop or Desktop PC. I notice that when I start up my Laptop, if I haven't already accessed Drive P: with for example, File Explorer, VFP cannot see my Projects. I have to go through the File Open Procedure to gain access. I understand that the cause is probably due to the Boot Up sequence of my Laptop not waiting to connect to the drive.

Can anyone suggest a way round this issue please?

Regards,

David.

Recreational user of VFP.
 
In your VFP startup routine, you can map to the drive programmatically. Something like this:
[pre]If Drivetype([P:]) = 1
Local wshnetwork As [wscript.network]
Local wshshell As [wscript.shell]
m.wshshell = Createobject([wscript.shell])
m.wshnetwork = Createobject([wscript.network])
m.wshnetwork.MapNetworkDrive([p:], [\\yourshare\yourfolder], .F., lcUsername, lcPassWord)
Release m.wshshell
Release wshnetwor
Endif
[/pre]
 
You shouldn't need to do that once you create the mapped drives with the option

reconnect_bbnfpx.png


If that doesn't work I'd look into Windows.

Bye, Olaf.

Olaf Doschke Software Engineering
 
Hi,

Sometimes my network drive - it's a NAS - needs more time to awake from hibernation than my laptop to boot. W10 usually throws an error icon on the right side of the taskbar - I only have to click that icon and my network drive restarts. You may want to check under "Taskbar settings - Taskbar - Select which icons appear on the taskbar". I'm using W10.

hth
MK
 
I wish my laptop would reboot so fast that was a problem for me

B-(

Think I need a new one.

Regards

Griff
Keep [Smile]ing

There are 10 kinds of people in the world, those who understand binary and those who don't.

I'm trying to cut down on the use of shrieks (exclamation marks), I'm told they are !good for you.
 
I do have a suggestion though, why not pop a shortcut to the drive into your startup folder, so windows opens it in Explorer as soon as you boot up?

Regards

Griff
Keep [Smile]ing

There are 10 kinds of people in the world, those who understand binary and those who don't.

I'm trying to cut down on the use of shrieks (exclamation marks), I'm told they are !good for you.
 
First of all, I apologise for not replying to the thread earlier, I have been recovering from a minor Hospital Procedure over the last few days.

Thank you all that replied to my original post. I am pleased to report that I have found the source of the problem; it was a Windows Update that had set "Fast Boot" to "on"; changing it to "off" solved the problem.

Regards,

David.

Recreational user of VFP.
 
Well done

Regards

Griff
Keep [Smile]ing

There are 10 kinds of people in the world, those who understand binary and those who don't.

I'm trying to cut down on the use of shrieks (exclamation marks), I'm told they are !good for you.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top