Connection failed for ASP.Net!
-
Hi All, OleDbConnection is working fine for C# windows appication same code is Failing for C# ASP application giving error "LOGIN Failed forJYOTHI/ASPNET" Where as JYOTHI is my system name as well as SQL Server Name I am not able to connect thru data wizard also. How can I rectify the problem. regards Jyothi
-
Hi All, OleDbConnection is working fine for C# windows appication same code is Failing for C# ASP application giving error "LOGIN Failed forJYOTHI/ASPNET" Where as JYOTHI is my system name as well as SQL Server Name I am not able to connect thru data wizard also. How can I rectify the problem. regards Jyothi
This is a permissions issue as you've no doubt worked out by the message "LOGIN Failed....". Why does it work in WinForms but not ASP.NET? Simply because when running a forms application the user is assumed to be the login-user, however when running as ASP.NET the default user is one named MACHINE-NAME/ASPNET. You have two options 1) Give the ASPNET user access to the database 2) Using web.config change the user to one which has access to the database.