views:

58

answers:

1

I am learning use VS 2008 setup project to create MSI installer for our C# application. The target system is Windows 7 embedded. Did some research online and couldn't find answers.

Because the application will be installed on Win7 machine. We need to put some files in C:\temp folder for read and write. how can I copy those files into C:\temp during the installation?

thanks,

+1  A: 

In your setup project:

  • Bring up the File System view.
  • Right-click on the pane, select Add Special Folder -> Custom Folder.
  • Right-click on that folder and select "Properties".
  • Change the Default Location property to "C:\temp".

Now add files to that folder in the project as appropriate.

Is there any reason the folder has to be, literally, "C:\temp"? That's not guaranteed to exist on every Windows system (though it sounds like you have control over your deployments).

Michael Petrotta
I tested with your answer, it will actually create one for you if not exist. I should ask here earlier to save me hours reading online which turns out nothing.
5YrsLaterDBA