drc_no1 wrote:
the connection string to the database. On my computer it is: connectionString="Data Source=DRC;Initial Catalog=Consulting_co;Integrated Security=True" providerName="System.Data.SqlClient" //from app.config as far as i know, datasource indicates the name of the sql server and this name must modify when the program is run from another place.
Well, you only need to modify it is the database is in another place. In an organisation setting each computer will point to the same SQL Server on the network. In your case you might want to just change Data Source=(local) instead. Specifying the server as (local), including the brackets, just means the default instance of SQL Server on this machine. Back to attaching and detaching the database. I tend not to do this. Usually I take a backup and then restore the backup on the target machine. The other thing you have to watch out for is user accounts. Logins are stored in the master database, the user permissions are stored on a per-database level. Off the top of my head I don't recall how to match them up again (if they get mismatched), but it is something you will have to consider.
Upcoming events: * Edinburgh: Web Security Conference Day for Windows Developers (12th April) * Glasgow: Introduction to AJAX (2nd May), SQL Server, Mock Objects My website