tags:

views:

19

answers:

1

Hello:

I have a WPF application that runs on a small database. Using clickonce or any one-click solution the users want to install the application locally and also set up the database at the same time. All users run SQL Server locally, so that is doable.

Can someone tell me how I can do that using a single mouse click?

Thanks PN

+4  A: 

The simplest approach would be to include a copy of the database with all tables, stored procedures etc. present in the installation package.

If you are using ClickOnce, make sure that the database is included as a "Data File (Auto)" in the Publish Status column and "(Required)" in the Download Group column.

Then as long as you reference the database via a relative path it should "just work" once it's been installed.

ChrisF