Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 21
Default Drive Letter of current file

With the help of many in this usergroup, I have finished my Excel "setup"
file (to "install" my Excel Addin in the proper folders, with shortcuts and
such). In this setupfile, I have an input box to get the "Source Drive"
(which may be unknown to novice users). Since the entire setup hinges on
the proper identification of the drive which contains this setup file (as
well as all the accompanying spreadsheets), I feel bad about getting the
drive letter by user input. Surely there must be a way to programmatically
discover the letter of the drive which has this "setup" file
("MySetup.xls"), to avoid the problem of users mis-identifying where
MySetup.xls resides. Is there?

I hope this is clear.

TIA


  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 11,272
Default Drive Letter of current file


left(Activeworkbook.fullname,2)

will return c:, Z:, etc. as long as the file has been saved.

--

HTH

Bob Phillips
... looking out across Poole Harbour to the Purbecks
(remove nothere from the email address if mailing direct)

"zSplash" wrote in message
...
With the help of many in this usergroup, I have finished my Excel "setup"
file (to "install" my Excel Addin in the proper folders, with shortcuts

and
such). In this setupfile, I have an input box to get the "Source Drive"
(which may be unknown to novice users). Since the entire setup hinges on
the proper identification of the drive which contains this setup file (as
well as all the accompanying spreadsheets), I feel bad about getting the
drive letter by user input. Surely there must be a way to

programmatically
discover the letter of the drive which has this "setup" file
("MySetup.xls"), to avoid the problem of users mis-identifying where
MySetup.xls resides. Is there?

I hope this is clear.

TIA




  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 3,885
Default Drive Letter of current file

Hi
try something like
msgbox Left(Activeworkbook.Fullname,2)

returns A: to Z:

--
Regards
Frank Kabel
Frankfurt, Germany

"zSplash" schrieb im Newsbeitrag
...
With the help of many in this usergroup, I have finished my Excel

"setup"
file (to "install" my Excel Addin in the proper folders, with

shortcuts and
such). In this setupfile, I have an input box to get the "Source

Drive"
(which may be unknown to novice users). Since the entire setup

hinges on
the proper identification of the drive which contains this setup file

(as
well as all the accompanying spreadsheets), I feel bad about getting

the
drive letter by user input. Surely there must be a way to

programmatically
discover the letter of the drive which has this "setup" file
("MySetup.xls"), to avoid the problem of users mis-identifying where
MySetup.xls resides. Is there?

I hope this is clear.

TIA



  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 80
Default Drive Letter of current file

Try this:

Left(ActiveWorkbook.Path,3)

HTH,
Nikos

"zSplash" wrote in message
...
With the help of many in this usergroup, I have finished my Excel "setup"
file (to "install" my Excel Addin in the proper folders, with shortcuts

and
such). In this setupfile, I have an input box to get the "Source Drive"
(which may be unknown to novice users). Since the entire setup hinges on
the proper identification of the drive which contains this setup file (as
well as all the accompanying spreadsheets), I feel bad about getting the
drive letter by user input. Surely there must be a way to

programmatically
discover the letter of the drive which has this "setup" file
("MySetup.xls"), to avoid the problem of users mis-identifying where
MySetup.xls resides. Is there?

I hope this is clear.

TIA




  #5   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 21
Default Drive Letter of current file

Excellent. Thank you so much, guys.

st.

"zSplash" wrote in message
...
With the help of many in this usergroup, I have finished my Excel "setup"
file (to "install" my Excel Addin in the proper folders, with shortcuts

and
such). In this setupfile, I have an input box to get the "Source Drive"
(which may be unknown to novice users). Since the entire setup hinges on
the proper identification of the drive which contains this setup file (as
well as all the accompanying spreadsheets), I feel bad about getting the
drive letter by user input. Surely there must be a way to

programmatically
discover the letter of the drive which has this "setup" file
("MySetup.xls"), to avoid the problem of users mis-identifying where
MySetup.xls resides. Is there?

I hope this is clear.

TIA






  #6   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 80
Default Drive Letter of current file

Try this:

Left(ActiveWorkbook.Path,3)

HTH,
Nikos

"zSplash" wrote in message
...
With the help of many in this usergroup, I have finished my Excel "setup"
file (to "install" my Excel Addin in the proper folders, with shortcuts

and
such). In this setupfile, I have an input box to get the "Source Drive"
(which may be unknown to novice users). Since the entire setup hinges on
the proper identification of the drive which contains this setup file (as
well as all the accompanying spreadsheets), I feel bad about getting the
drive letter by user input. Surely there must be a way to

programmatically
discover the letter of the drive which has this "setup" file
("MySetup.xls"), to avoid the problem of users mis-identifying where
MySetup.xls resides. Is there?

I hope this is clear.

TIA




  #7   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 21
Default Drive Letter of current file

Thanks, guys.

st.

"zSplash" wrote in message
...
With the help of many in this usergroup, I have finished my Excel "setup"
file (to "install" my Excel Addin in the proper folders, with shortcuts

and
such). In this setupfile, I have an input box to get the "Source Drive"
(which may be unknown to novice users). Since the entire setup hinges on
the proper identification of the drive which contains this setup file (as
well as all the accompanying spreadsheets), I feel bad about getting the
drive letter by user input. Surely there must be a way to

programmatically
discover the letter of the drive which has this "setup" file
("MySetup.xls"), to avoid the problem of users mis-identifying where
MySetup.xls resides. Is there?

I hope this is clear.

TIA




Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Force linked files to link as a drive letter, not UNC name Q Excel Discussion (Misc queries) 0 March 24th 09 11:41 PM
Obtain drive letter assignment of CD/DVD drive? EagleOne Excel Discussion (Misc queries) 1 October 13th 06 01:27 PM
How to show the drive letter in the path on the title bar? Jim Excel Discussion (Misc queries) 6 July 2nd 06 10:19 AM
Can I show server name instead of drive letter? bfant Excel Discussion (Misc queries) 9 February 17th 05 06:11 AM
How to find the drive letter? Mervyn Thomas Excel Programming 8 January 31st 04 01:11 PM


All times are GMT +1. The time now is 07:54 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"