Connection Problem

hbfash

New Member
This Connection String is causing me a problem....<BR><BR>SqlConnection myConnection = new SqlConnection("server=server;database=tmf;UID=sa;Password=passwor d"); <BR><BR>"server" is the databse server in the network, well this string is working fine in this way.. <BR><BR>SqlConnection myConnection = new SqlConnection("server=(local)\NetSDK;database=pubs;Trusted_Connec tion=yes"); <BR><BR>but this is the my own machine infact this is the test database installed with .net framework sdk and it is running fine but when i attempt to connect to my databse server it says sql server does not exists or no rights etc. but i m running so many simple ASP applications with the above coonection string and not having any problem but why in ASP .Net.. The above code is in C# I have also tried in VB. Net too but same results :( .. any idea now??I've never trusted trusted_connection :) (just kidding)<BR><BR>Have you tried connected to your local machine with the same string you mentioned first, but edited to reflect your machine?
 
Back
Top