Make directory structure variable
You can find the "my documents" path with something like:
Option Explicit
Sub testme()
Dim myDocumentsPath As String
Dim wsh As Object
Set wsh = CreateObject("WScript.Shell")
myDocumentsPath = wsh.SpecialFolders.Item("mydocuments")
MsgBox myDocumentsPath
End Sub
Pepestru wrote:
A macro ends with saving the worksheet. It works for me, but but not for
other users that use my worksheet on their PC. I found my solution in the
knowledge base, but I cant find how to make it flexible.
My macro ends with:
ActiveWorkbook.SaveAs Filename:="C:\Documents and Settings\Owner\My
Documents\VvEAH\Financ\2007\Bookdoc " & Format(Now, "yyyy-mm") & ".xls"
How do I adjust this statement to make it usefull for all users.
Thanks for your help.
Paul
--
Dave Peterson
|