PearlGI
Registered User.
- Local time
- Today, 13:09
- Joined
- Aug 30, 2001
- Messages
- 125
Here's the scenario:
I have a routine in Access that outputs a series of reports as .rtf files into a directory on a network. It then changes all of the file attributes of these files to read-only.
This is successful in preventing users from changing the reports, but this doesn't prevent them from (knowingly or otherwise!) saving their own versions of the report into the same directory.
I can change the attributes of the directory to read-only using VBA, but this doesn't appear to have any effect.
However, if I manually change the directory permissions to Read from Full Control using NT Explorer this does exactly what I need, BUT I need to be able to repeat this using VBA?
Two questions:
1. Is this possible using VBA?
2. Can anyone provide any sample code?
I have a routine in Access that outputs a series of reports as .rtf files into a directory on a network. It then changes all of the file attributes of these files to read-only.
This is successful in preventing users from changing the reports, but this doesn't prevent them from (knowingly or otherwise!) saving their own versions of the report into the same directory.
I can change the attributes of the directory to read-only using VBA, but this doesn't appear to have any effect.
However, if I manually change the directory permissions to Read from Full Control using NT Explorer this does exactly what I need, BUT I need to be able to repeat this using VBA?
Two questions:
1. Is this possible using VBA?
2. Can anyone provide any sample code?