本文介绍了'/ MyWebForm'应用程序中的服务器错误的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧! 问题描述 29岁程序员,3月因学历无情被辞! 我遇到一个问题,涉及我在尝试完成asp.net Web应用程序示例时获得的错误(演练:创建Web 使用第三个应用程序) -Party Business Object)。当我第一次在VS.NET 2003中创建 SQL连接时,我测试连接并且一切正常工作 罚款。但是,当我尝试运行应用程序的第一阶段(绑定的 数据网格)时,我收到一条错误消息: 用户登录失败' 'DELL340 \ASPNET''。 此新闻组中有另一篇关于此主题的帖子(难度 连接到SQL Server 2000:2002-03- 04)建议下线: < identity impersonate =" true" /> Web.config文件中的但是当我再次运行应用程序时,会出现以下 失败消息: 用户''DELL340 \\\ n \\ _AUDR_DELL340'登录失败。 用户如何更改以及用户名来自何处? 我该怎么做才能解决问题? 我附上了第二条错误消息的全文。系统是Windows XP, SP2。 MSDE服务器。 Ed。 - Edward E.L. Mitchell 网址: www.racesail.org 电话:(508)771-0806 500海洋街,134单元, 海恩尼斯,MA 02601 $ b $'/ MyWebForm''应用程序中的$ b服务器错误。 ----------------------------- -------------------------------------------------- - 用户''DELL340\IUSR_DELL340'登录失败。 描述:执行 $期间发生未处理的异常b $ b当前的网络请求。请查看堆栈跟踪以获取更多信息 关于错误及其在代码中的起源。 异常详细信息:System.Data.SqlClient.SqlException:用户登录失败 ''DELL340 \IUSR_DELL340''。 来源错误: 第48行:public void FillDataSet(myDataSet dSet) 第49行:{ 第50行:sqlDataAdapter1.Fill(dSet); 第51行:} 第52行: 源文件:c:\inetpub \wwwroot \ mywebform \ component1.cs行:50 堆栈跟踪: [SqlException:用户''DELL340\IUSR_DELL340''登录失败。] System.Data .SqlClient.ConnectionPool.GetConnection(布尔& isInTransaction)+472 System.Data.SqlClient.SqlConnectionPoolManager.Get PooledConnection(SqlConnectionString options ,布尔& isInTransaction)+ 372 System.Data.SqlClient.SqlConnection.Open()+384 System.Data.Common.DbDataAdapter.QuietOpen(IDbConnction连接, ConnectionState& originalState)+44 System.Data.Common.DbDataAdapter.FillFromCommand(O bject data,Int32 startRecord,Int32 maxRecords,String srcTable,IDbCommand command, CommandBehavior行为)+304 System.Data.Common.DbDataAdapter.Fill(DataSet dataSet,Int32 startRecord, Int32 maxRecords,String srcTable,IDbCommand command, CommandBehavior 行为)+77 System.Data.Common.DbDataAdapter.Fill(DataSet dataSet)+38 MyWebForm.Component1.FillDataSet( myDataSet dSet) c:\inetpub \ www.root \ mywebform \ component1.cs:50 MyWebForm.WebForm1.Page_Load(Object sender,EventArgs e)in c:\inetpub \wwwroot \ mywebform\webform1.aspx.cs:27 System.Web.UI.Control.OnLoad(EventArgs e)+67 System.Web.UI.Control.LoadRecursive()+35 System.Web.UI.Page.ProcessRequestMain()+ 731 ------------------------------------------ -------------------------------------- 版本信息:Microsoft .NET Framework版本:1.1.4322.573; ASP.NET 版本:1.1.4322.573I have a problem that involves the error I receive when attempting tocomplete the asp.net web application example (Walkthrough: Creating a WebApplication Using a Third-Party Business Object). When I first create theSQL connection in VS.NET 2003, I test the connection and everything worksfine. However, when I attempt to run the first stage of the app (the bounddatagrid), I receive an error stating:login failed for user ''DELL340\ASPNET''.There was another post in this newsgroup on this subject (Difficultyconnecting to SQL Server 2000:2002-03-04) that suggested placing the line:<identity impersonate="true" />in the Web.config file but when I run the app again, there is the followingfailure message:Login failed for user ''DELL340\IUSR_DELL340''.How come the user changed and where did the user name come from?What can I do to fix the problem?I appended the full text of the second error message. System is Windows XP,SP2. MSDE server.Ed.--Edward E.L. MitchellWeb: www.racesail.orgPhone: (508)771-0806500 Ocean St., Unit 134,Hyannis, MA 02601Server Error in ''/MyWebForm'' Application.--------------------------------------------------------------------------------Login failed for user ''DELL340\IUSR_DELL340''.Description: An unhandled exception occurred during the execution of thecurrent web request. Please review the stack trace for more informationabout the error and where it originated in the code.Exception Details: System.Data.SqlClient.SqlException: Login failed for user''DELL340\IUSR_DELL340''.Source Error:Line 48: public void FillDataSet(myDataSet dSet)Line 49: {Line 50: sqlDataAdapter1.Fill(dSet);Line 51: }Line 52:Source File: c:\inetpub\wwwroot\mywebform\component1.cs Line: 50Stack Trace:[SqlException: Login failed for user ''DELL340\IUSR_DELL340''.]System.Data.SqlClient.ConnectionPool.GetConnection (Boolean&isInTransaction) +472System.Data.SqlClient.SqlConnectionPoolManager.Get PooledConnection(SqlConnectionStringoptions, Boolean& isInTransaction) +372System.Data.SqlClient.SqlConnection.Open() +384System.Data.Common.DbDataAdapter.QuietOpen(IDbConn ection connection,ConnectionState& originalState) +44System.Data.Common.DbDataAdapter.FillFromCommand(O bject data, Int32startRecord, Int32 maxRecords, String srcTable, IDbCommand command,CommandBehavior behavior) +304System.Data.Common.DbDataAdapter.Fill(DataSet dataSet, Int32 startRecord,Int32 maxRecords, String srcTable, IDbCommand command, CommandBehaviorbehavior) +77System.Data.Common.DbDataAdapter.Fill(DataSet dataSet) +38MyWebForm.Component1.FillDataSet(myDataSet dSet) inc:\inetpub\wwwroot\mywebform\component1.cs:50MyWebForm.WebForm1.Page_Load(Object sender, EventArgs e) inc:\inetpub\wwwroot\mywebform\webform1.aspx.cs:27System.Web.UI.Control.OnLoad(EventArgs e) +67System.Web.UI.Control.LoadRecursive() +35System.Web.UI.Page.ProcessRequestMain() +731--------------------------------------------------------------------------------Version Information: Microsoft .NET Framework Version:1.1.4322.573; ASP.NETVersion:1.1.4322.573推荐答案 这篇关于'/ MyWebForm'应用程序中的服务器错误的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持! 上岸,阿里云!
08-29 00:10