problems connecting to my SQL server database in .NET

I am able to connect and display data in classic asp just fine, but I cannot connect to my database using ASP.NET.

I have tried 2 tutorials on here and neither has worked. They both give me the same error: "Login failed for user 'NASHIE\ASPNET'."
I am currently working on this tutorial:
"Display Data with MxDataGrid"
[wmx:SqlDataSourceControl id="SqlDataSourceControl1" runat="server" UpdateCommand="" SelectCommand="SELECT * FROM [Orders]" ConnectionString="server='(local)'; trusted_connection=true; database='MatrixOrders'" DeleteCommand=""][/wmx:SqlDataSourceControl]
That is my connection string, but it won't work at all.
When I work with classic ASP my connection strings are generally like this:
Set Conn = CreateObject("ADODB.Connection")
Conn.Open "Provider=SQLOLEDB;Data Source=localhost;" & _
"Initial Catalog=my_database;Network=DBMSSOCN;" & _
"User Id=SECRET;Password=SECRET"
I've tried inserting a username and password into the SqlDataSourceControl but to no avail. Anybody know whats wrong, its driving me nuts.
1/7/2005 6:10:39 PM 16182 articles. 0 followers. Follow

0 Replies

Similar Articles

[PageSpeed] 29