"deko" <ww*******************************@nospam.com> wrote in message
news:E3******************@newssvr29.news.prodigy.c om...
Yes , you start your development by connecting your application to the
SQL
server
on your local network.
Can you point me to any information about how to do this?
When you want ASP.NET to use ADO.NET to interface with SQL Server, you will
typically use the System.Data.SqlClient namespace, and the "standard" way of
telling ADO.NET where the SQL Server is and how to connect to it is by means
of a connection string. A popular method of storing this information in
ASP.NET is in the Web.config file e.g.
<configuration>
<appSettings>
<add key="SQLConnectionString" value="Data Source=devmachine;Initial
Catalog=devdatabase;User ID=devuser;Password=devpassword" />
</appSettings>
</configuration>
This connection string is then availalble to ASP.NET via the code:
System.Configuration.ConfigurationSettings.AppSett ings["SQLConnectionString"])
The above string assumes that you have SQL Server installed on a machine
called devmachine with a database called devdatabase and a user called
devuser with a password of devpassword. Obviously, you will change these
various elements to reflect your own development environment.
Then, when you're ready to deploy your ASP.NET project to your remote
server, you will simply change the values in the connection string so that
ADO.NET will point at your live SQL Server instead of your development one.
Also, of you're concerned that the connection string is plain text, encrypt
it e.g.
<configuration>
<appSettings>
<add key="SQLConnectionString"
value="/jrER8bDAM8VfdvPuMkGw033IhEYg2c9voBQcmL3f6VKoj3VZ4c o9uZU8sHunQwCN3oL2uGCbDbC/9Rrix5yHdfzYXXGisa2"
/>
</appSettings>
</configuration>