How to connect to my Database stored in remote computer with VB.Net
-
I have a project I am using it in my local computer , when I tested my Database in a remote SQL server 2005 computer, it is giving error , while i can connect through SQL server installed in my computer to that SQL server instance and I can work on those Database I can not connect through VB.Net the code writen is as bellow it says to enable the TCP/pipe while both of them are enabled in remote computer. con = New SqlConnection(" data source =\\servername\instancename; database = Employee;" & "uid=test; pwd=test")
-
I have a project I am using it in my local computer , when I tested my Database in a remote SQL server 2005 computer, it is giving error , while i can connect through SQL server installed in my computer to that SQL server instance and I can work on those Database I can not connect through VB.Net the code writen is as bellow it says to enable the TCP/pipe while both of them are enabled in remote computer. con = New SqlConnection(" data source =\\servername\instancename; database = Employee;" & "uid=test; pwd=test")
If you have the servername right, then it's a network issue, or a configuration issue on SQL Server.
Christian Graus Driven to the arms of OSX by Vista. "I am new to programming world. I have been learning c# for about past four weeks. I am quite acquainted with the fundamentals of c#. Now I have to work on a project which converts given flat files to XML using the XML serialization method" - SK64 ( but the forums have stuff like this posted every day )
-
I have a project I am using it in my local computer , when I tested my Database in a remote SQL server 2005 computer, it is giving error , while i can connect through SQL server installed in my computer to that SQL server instance and I can work on those Database I can not connect through VB.Net the code writen is as bellow it says to enable the TCP/pipe while both of them are enabled in remote computer. con = New SqlConnection(" data source =\\servername\instancename; database = Employee;" & "uid=test; pwd=test")
I am just a beginner so I could well be wrong here but I thought that; unless the remote server is on the same domain as the local machine then you are unable to connect to it by using a UNC? (i.e. \\servername) Is this incorrect? Have you tried connecting to it by using its IP address?
-
I have a project I am using it in my local computer , when I tested my Database in a remote SQL server 2005 computer, it is giving error , while i can connect through SQL server installed in my computer to that SQL server instance and I can work on those Database I can not connect through VB.Net the code writen is as bellow it says to enable the TCP/pipe while both of them are enabled in remote computer. con = New SqlConnection(" data source =\\servername\instancename; database = Employee;" & "uid=test; pwd=test")
http://www.connectionstrings.com[^] Check your connection string
-
I have a project I am using it in my local computer , when I tested my Database in a remote SQL server 2005 computer, it is giving error , while i can connect through SQL server installed in my computer to that SQL server instance and I can work on those Database I can not connect through VB.Net the code writen is as bellow it says to enable the TCP/pipe while both of them are enabled in remote computer. con = New SqlConnection(" data source =\\servername\instancename; database = Employee;" & "uid=test; pwd=test")
-
I have a project I am using it in my local computer , when I tested my Database in a remote SQL server 2005 computer, it is giving error , while i can connect through SQL server installed in my computer to that SQL server instance and I can work on those Database I can not connect through VB.Net the code writen is as bellow it says to enable the TCP/pipe while both of them are enabled in remote computer. con = New SqlConnection(" data source =\\servername\instancename; database = Employee;" & "uid=test; pwd=test")
Ensure you have the SQL server configured properly, user/group permissions, and check the *firewall* on the server and client.
Any suggestions, ideas, or 'constructive criticism' are always welcome. "There's no such thing as a stupid question, only stupid people." - Mr. Garrison