Home |
Search |
Today's Posts |
|
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
recognize USB drive
Is there a way to see if there is a USB memory stick connected to the PC within a macro? -- lcoreyl ------------------------------------------------------------------------ lcoreyl's Profile: http://www.excelforum.com/member.php...fo&userid=2042 View this thread: http://www.excelforum.com/showthread...hreadid=472292 |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
recognize USB drive
Yes. create a small .bat file that attempts to do a DIR to the logical drive
unit. Run the .bat file thru a SHELL command from VBA. If you get back the standard error message that the system could not find the path specified, then the drive is not connected. -- Gary''s Student "lcoreyl" wrote: Is there a way to see if there is a USB memory stick connected to the PC within a macro? -- lcoreyl ------------------------------------------------------------------------ lcoreyl's Profile: http://www.excelforum.com/member.php...fo&userid=2042 View this thread: http://www.excelforum.com/showthread...hreadid=472292 |
#3
Posted to microsoft.public.excel.programming
|
|||
|
|||
recognize USB drive
Gary''s Student Wrote: Yes. create a small .bat file that attempts to do a DIR to the logical drive unit. Run the .bat file thru a SHELL command from VBA. If you get back the standard error message that the system could not find the path specified, then the drive is not connected. -- Gary''s Student "lcoreyl" wrote: Is there a way to see if there is a USB memory stick connected to the PC within a macro? -- lcoreyl ------------------------------------------------------------------------ lcoreyl's Profile: http://www.excelforum.com/member.php...fo&userid=2042 View this thread: http://www.excelforum.com/showthread...hreadid=472292 That won't work as different users will have different drive letters. Is there a way to use the DIR function to find out what drives exist? -- lcoreyl ------------------------------------------------------------------------ lcoreyl's Profile: http://www.excelforum.com/member.php...fo&userid=2042 View this thread: http://www.excelforum.com/showthread...hreadid=472292 |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Links to mapped drive change to refer to local hard drive | Links and Linking in Excel | |||
Can I save to hard drive AND my flash drive at the same time? | Excel Discussion (Misc queries) | |||
Userform Local Drive & Network drive question | Excel Programming | |||
Pasting a range of information from a foler on F Drive to another folder on same drive | Excel Programming | |||
Find links with code; change from G drive to C drive | Excel Programming |