connection string
-
this is my connection string... SqlConnection objCon = new SqlConnection("Data Source=VEESERV4;Initial Catalog=DemoInven;User ID=sa;Password=sa"); i give data source = veeserv4... instead of this i have to give one word file their... and the corresponding text in that word file is taken as data source name... how can i do this...
-
this is my connection string... SqlConnection objCon = new SqlConnection("Data Source=VEESERV4;Initial Catalog=DemoInven;User ID=sa;Password=sa"); i give data source = veeserv4... instead of this i have to give one word file their... and the corresponding text in that word file is taken as data source name... how can i do this...
kulandaivel_mca2007 wrote:
instead of this i have to give one word file their... and the corresponding text in that word file is taken as data source name...
Why ??:confused:
cheers, Abhijit CodeProject MVP My Recent Article : Exploring Session in ASP.Net
-
this is my connection string... SqlConnection objCon = new SqlConnection("Data Source=VEESERV4;Initial Catalog=DemoInven;User ID=sa;Password=sa"); i give data source = veeserv4... instead of this i have to give one word file their... and the corresponding text in that word file is taken as data source name... how can i do this...
Try this SqlConnection objCon = New SqlConnection(ConfigurationManager.ConnectionStrings["VEESERV4"].ConnectionString)
-
kulandaivel_mca2007 wrote:
instead of this i have to give one word file their... and the corresponding text in that word file is taken as data source name...
Why ??:confused:
cheers, Abhijit CodeProject MVP My Recent Article : Exploring Session in ASP.Net
projects are submitted in exe file format... so he(client) not able to change datasource name... if the datasource name taken from word file... he can change easily..
-
projects are submitted in exe file format... so he(client) not able to change datasource name... if the datasource name taken from word file... he can change easily..
kulandaivel_mca2007 wrote:
projects are submitted in exe file format...
You have to use configure file app.config for Windows applications[^] You can also Encrypt it Encrypting the app.config File for Windows Forms Applications[^]
cheers, Abhijit CodeProject MVP My Recent Article : Exploring Session in ASP.Net