【发布时间】:2013-05-24 17:17:20
【问题描述】:
我正在尝试做一些非常简单的事情,但遇到了一个我已经尝试了两天来修复的错误。我有一个简单的 ASP 按钮从代码隐藏调用函数(见下文)......我收到以下错误。但只有当我将网站上传到 Azure 时,它才能在模拟时正确运行。
SCRIPT5007: Unable to get property 'PRM_ServerError' of undefined or null reference
MicrosoftAjaxWebForms.js,第 5 行字符 11118
ASP Button 定义如下,没什么特别的...
<asp:Button CausesValidation="false" ID="Button1" runat="server" Text="Login" OnClick="radbtn_loginButton_Click" />
又是后面的代码...疯狂的简单...
protected void radbtn_loginButton_Click(object sender, EventArgs args)
{
try
{
string uName;
string uPass;
uName=UsernameBox.Value;
uPass=PasswordBox.Value;
if(uName=="admin" && uPass=="password")
{
Response.Redirect("dsxHome.aspx");
}
else
{
loginMessage.Text="Login Invalid!";
}//end if
}
catch
{
loginMessage.Text="Problem with Login";
}
}
消息标签嵌套在 AjaxPanel 中...我正在站点的其他页面的其他地方进行其他 Ajax 调用...但最简单的一个正在中断...
任何想法...我知道我错过了一些愚蠢的东西...
迈克尔
【问题讨论】: