Solve the first time in order to complete the symbolic operation of the use of ASP.net, asp.net ah, Khan. So immediately ran into a problem, I now write the question, for the development of ASP.net people, this question should not become a problem, I also just contact with asp.net people. The following error occurred while trying the DataGrid last night:
A server error in the "/datagridtest" application.
--------------------------------------------------------------------------------
User ' Hp-2v47vi88m4gb\aspnet ' login failed.
Note: An unhandled exception occurred during the execution of the current WEB request. Check the stack trace for more information about the error and where the error occurred in the code.
Exception Details: System.Data.SqlClient.SqlException: User ' hp-2v47vi88m4gb\aspnet ' login failed.
SOURCE Error:
Row 31:if (!this. IsPostBack)
Line 32: {
Line 33:sqldataadapter1.fill (dataset11,0,10, "products");
Line 34:this. DataBind ();
Line 35:}
==============================================================================
According to my present exception, my solution is as follows:
1, create "Computer name \aspnet" user in SQL Server. Like I created Hp-2v47vi88m4gb\aspnet.
2. Open the Security folder in SQL Enterprise Manager, right-click "Login" and select "New Login ...". General tab, name fill hp-2v47vi88m4gb\aspnet, other default, Database Access tab, specify the database to access, I specify the Northwind database, and then give him permission: Dbo,public is enough.
If there is a better way, please advise
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.