Ajax的问题,下列代码如果去掉<asp:UpdatePanel> </asp:UpdatePanel> 就可以正常运行
<%@ Page Language= "C# " AutoEventWireup= "true " CodeFile= "Default6.aspx.cs " Inherits= "Default6 " %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN " "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd ">
<html xmlns= "http://www.w3.org/1999/xhtml " >
<head runat= "server ">
<title> 无标题页 </title>
</head>
<body>
<form id= "form1 " runat= "server ">
<asp:ScriptManager ID= "ScriptManager1 " runat= "server " EnablePageMethods= "True " />
<div>
<asp:UpdatePanel ID= "UpdatePanel2 " runat= "server " >
<ContentTemplate>
<asp:PlaceHolder ID= "PlaceHolder1 " runat= "server ">
<div class= "demoarea ">
<div >
<asp:LinkButton ID= "lbtnAdd " runat= "server " CausesValidation=false OnClick= "lbtnAdd_Click "> 新增 </asp:LinkButton>
<asp:LinkButton ID= "LinkButton1 " style= "display:none; " runat= "server " > LinkButton </asp:LinkButton>
</div>
<div>
<asp:Panel ID= "Panel1 " runat= "server " Style= "display: none " Width=300 Height=200 BackColor= "LightGray " CssClass= "modalPopup " >
<asp:Panel Width=100% ID= "Panel3 " runat= "server " Style= "cursor: move;background-color:#DDDDDD;border:solid 1px Gray;color:Black ">
<div>
<p> </p>