View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.programming
Melanie Breden Melanie Breden is offline
external usenet poster
 
Posts: 88
Default How to get the full path name of the open workbook in a macro

How can I get the full path name for the open workbook using a macro? I
have tried using the CurDir() function but it is not working.

eg. If I open my workbook from C:\Data\Excel\, I want to be able to get
this string "C:\Data\Excel\"


try this:

strPath = ActiveWorkbook.Path & "\"

--
Regards
Melanie Breden
- Microsoft MVP für Excel -

http://excel.codebooks.de (Das Excel-VBA Codebook)