Click here to Skip to main content
15,907,910 members
Please Sign up or sign in to vote.
2.00/5 (1 vote)
See more:
Hi.. friends is that possible in vb.net that we can save or retrieve data from sql without define the connection string only in single table if it is possible then tell me how, please I need the help of you.

Thanks in advance

Parveen Rathi
Posted
Comments
nagendrathecoder 20-Sep-11 6:05am    
What do your mean by "only in single table"??
Parveen Rathi 20-Sep-11 6:30am    
I want a table to store data which not use the sql connection string, because it can be changed
Prerak Patel 20-Sep-11 6:06am    
No, you can't.

No. Not possible. Without using connection string your program will not identify the server, database, table.

If you don't want to define the connection string in web.config file, you can directly use the connection string in the SqlConnection object.
SQL
Dim sqlCon as New SqlConnection("server='servername';Initial Catalog='databasename';user id='username';password='password'")
 
Share this answer
 
v4
You can broadcast a UDP request and get back your connection string from a server at runtime, circumventing the need for a client side connection string.
 
Share this answer
 
Comments
Herman<T>.Instance 20-Sep-11 6:13am    
any resources to show to have this work?
Mehdi Gholam 20-Sep-11 6:55am    
You have to create a windows service that listens to UDP request and sends a config file in return, great idea, I'm working on it.

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900