CurDir will return the current default path.
ThisWorkbook.Path will return the path of the workbook containing the code.
ActiveWorkbook.Path will return the path of the workbook that is currently
active, which may or may not be the workbook containing the code.
--
Cordially,
Chip Pearson
Microsoft MVP - Excel
Pearson Software Consulting LLC www.cpearson.com
(email on the web site)
This is the code I came up with. It seems to work so I guess that is all I
need. I don't think I need to password it.
With ActiveWorkbook.Worksheets("sheet1")
.Parent.SaveAs Filename:=.Range("B1").Value & .Range("C1"). _
Value & .Range ("E1").Value & ".xls"
End With
Thanks everyone
Ask a Question
Want to reply to this thread or ask your own question?
You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.