do a bit of searching and you will find solutions - such as
here
What I did in my last project was to leave the connections string with a non valid value in the config, and my application checked it at start up and invoked a connections string editing form if it was invalid.
This has the advantage that, should the client need to change the location of their database, the application has the functionality available to change the connection string.