Local Or Remote Sql Server Databse Connection String in configuration file (web.config)
LOCAL DATABASE SERVERYou don't need the username and password to access the local database server.
REMOTE DATABASE CONNECTION STRING WITH IP, USERNAME AND PASSWORD METHOD 1
EXAMPLE:
REMOTE DATABASE CONNECTION STRING WITH IP, USERNAME AND PASSWORD METHOD 2
EXAMPLE:
Writing the above database connection string in Web.config file as shown below
Now, write the below code to get the connection string from web.config file in your CS file.
No comments