I am unable to get a file to copy during installation. Here's the background.
This is a Winforms project, C# in VS2017. It connects to a local MSAccess database. I need to install this .accdb where any user running the application can read and write to it. In my Solution, I'm working with a Windows Deployment Project.
My searches indicated that the CommonAppDataFolder is the place for this. That particular folder however is not offered by in the VS IDE, but I can create it, and my installed exe's recognize it.
The installation creates the folder, but it fails to copy the file into it during installation.
How can I get this file to copy during install and so that all users of my application can read/write to it?
Thanks for helping.
What I have tried:
In my deployment project, in File System Editor, I have done:
Add Special Folder, Custom Folder, and set its properties as:
Name: CommonAppDataFolder
AlwaysCreate: True
Condition:
DefaultLocation: [CommonAppDataFolder]
Property: COMMONAPPDATAFOLDER
Then on that folder, I've done:
Add, File... and navigated to and selected my .accdb.
The file properties are (I have made no changes):
Condition:
Exclude: False
Folder: CommonAppDataFolder
Hidden: False
PackageAs: vsdpaDefault
Permanent: False
ReadOnly: False
Register: vsdrfDoNotRegister
SharedLegacyFile: False
SourcePath: C:\Users\Armstrong1\Documents\Visual Studio 2017\Projects\ArmstrongAnalytics\ArmstrongAnalytics\App_Data\DHHScreen.accdb
System: False
TargetName: DHHScreen.accdb
Transitive: False