Multi-user file save

G

Guest

I am creating a company survey and want to email the Excel document to all
employees. They will need to save it to a common file on our network and
also I want to keep it confidential. I was thinking of creating a macro that
was a "save as" and assigning it to a button - first of all will that work?
Second - can I create a "save as" that adds the date and exact time to the
document so that each form that is completed is saved seperately? (PS: to say
that I am a novice might be an compliment)
 
R

Ron de Bruin

Hi DeAnna

Look in the VBA help for SaveCopyAs

ActiveWorkbook.SaveCopyAs "C:\Copy of " & ActiveWorkbook.Name & " " & Format(Now, "dd-mmm-yy h-mm-ss") & ".xls"
 
N

NickHK

Ron has shown you the necessary SaveAs code.
If you create a suitable network folder that everyone has write permission,
but not read permission, you can hard code that UNC path into the SaveAs.
That way everyone will save to the same place, but will not be able to see
other's information.

\\servername\sharedfolder\SurveyReplies\ & ActiveWorkbook.Name & " " &
Format(Now, "dd-mmm-yy h-mm-ss") & ".xls"

Of course, this assumes that no 2 people try to save at exactly the same
second. Likely ?

NickHK
 

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.

Ask a Question

Top