File Name and Full Path Name
Dim wkbk as workbook
set wkbk = activeworkbook 'thisworkbook or workbooks("book1.xls")
msgbox wkbk.name
msgbox wkbk.Fullname
msgbox wkbk.Path
If you're creating a new workbook in your code and you want to test to see if
it's been saved:
if wkbk.path = "" then
'not saved
else
'saved
end if
Jess wrote:
How can I get in excel the file name and the full path to the file? Is there
a VBA command that retrieves this info?
Thanks
--
Dave Peterson
|