[Last Call] Learn how to a build a cloud-first strategyRegister Now

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 265
  • Last Modified:

Check for Network Drive Availability

I have a spreadsheet that uses a form to guide users in entering information in a workbook.  After the user performs a task the spreadsheet will save.  The file saves on a server that sometimes goes down and the drive is no longer available to the spreadsheet on saving.  I will then have it redirect the filesave to the users own hard drive.  I would like to know the code necessary to check to see whether the drive is available before the save routine begins.
0
DavidH7470
Asked:
DavidH7470
1 Solution
 
Rory ArchibaldCommented:
On a simplistic level, you could simply use On Error Resume Next, save to the network, then check if err.number <> 0 and in that case save locally.
0
 
SiddharthRoutCommented:
Here is a cool link which I always use.

Topic: Enumerating Local and Network Drives
Link: http://access.mvps.org/access/api/api0003.htm

HTH

Sid
0
 
RamanhpCommented:
besides rorya, u may like this way out too


store savelocation = network drive path

check if savelocation is empty, then savelocation = local drive path

check if savelocation not empty, then save at savelocation
0
 
DavidH7470Author Commented:
Sometimes simple is best
0

Featured Post

Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Tackle projects and never again get stuck behind a technical roadblock.
Join Now