i m working on win. application , it using ms access as a database.
When i install it then .mdb file become readonly , now i can't update and save record.
How i can do that when i install it then it not become readonly?
Loading
Know the answer? Post it — somebody with the same question will find it here.
Sign in to answer this question
It is the same account you read, post and publish with — and you will come straight back to this page.
Jean PaulPosted Oct 27, 2010, 4:36 AM
I can say two solutions for the problem. (assume you are using visual studio setup and deployment project)
1) Choose the setup project, right click and select View File system menu item.
Select the access file and press F4 to see the properties window. Mark the property ReadOnly to false.
Try building the setup and execute it. If the problem persists please do the solution 2.
2) Right click on the setup project, and chose View>Custom Actions. Here you can specify the actions
you need to do after install. Right click on the "Commit" section in the appearing window and chose
"Add Custom Action". Select an exe file that is pre-existing which would make the file as writable.
(You need to create a separate console application, which on the startup will access the current directory and
make the file writable.)
Please make sure that the custom action file property "InstallerClass" is set to false.
Note
If the problem still persists please let me know (else mark as answer)
irfan jahangirPosted May 26, 2014, 10:14 AM
Vikas AhlawatPosted Oct 27, 2010, 5:15 AM