Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

File Access Question 1

Status
Not open for further replies.

pluto1415

MIS
Apr 28, 2009
78
US
Not sure where to ask this one, but you guys have been EXTREMELY helpful in the past so I thought I'd start here.

I've got an Access DB, that runs some queries and some VBA and merges about 25 files on-demand for me. Those files that it merges are MSWord documents that are stored on a network share. I'm having an issue that one of my users, instead of running the VBA from Access as they are supposed to, have gone into the files themselves and made some changes to the MSWord files. I can't have my end-users making changes to my original files because when they do, the Access VBA breaks and doesn't run correctly. I have some bad feelings about why this user is doing this, but that's not a discussion for here.

I understand the user MUST have access to the MSWord files to be able to run the VBA, but is there a way I can make sure they cannot access the files directly?
 
You can password-protect the files, but I don't know if they can be manipulated then by VBA or not.

Beir bua agus beannacht!
 
Thanks - this got me thinking in the right direction.

I did password protect them - then in my documents.open line, I added PasswordDocument:="password"

If you do this, it saves the new document with the password, which I don't want, so I added this to my activedocument.saveas Password:=""

This allows the user to open and manipulate the new document that is created, without giving them the right to open my original file.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top