页面正常运行,后来我加了一段脚本就提示这样一个错误,以前也有过这种问题,请大家帮我分析一下:
我加的脚本就是onTextChanged后面那些
Compilation Error
Description: An error occurred during the compilation of a resource required to service this request. Please review the following specific error details and modify your source code appropriately. Compiler Error Message: CS1026: 应输入 )Source Error: Line 33: <asp:Label id=Label1 runat="server" Text='<%# DataBinder.Eval(Container, "DataItem.EmployeeID") %>'>
Line 34: </asp:Label>
Line 35: <asp:TextBox id=TextBox1 runat="server" Text='<%# DataBinder.Eval(Container, "DataItem.LastName") %>' OnTextChanged="javascript:this.parentElement.children(0).checked=true;">
Line 36: </asp:TextBox>
Line 37: </ItemTemplate>
我加的脚本就是onTextChanged后面那些
Compilation Error
Description: An error occurred during the compilation of a resource required to service this request. Please review the following specific error details and modify your source code appropriately. Compiler Error Message: CS1026: 应输入 )Source Error: Line 33: <asp:Label id=Label1 runat="server" Text='<%# DataBinder.Eval(Container, "DataItem.EmployeeID") %>'>
Line 34: </asp:Label>
Line 35: <asp:TextBox id=TextBox1 runat="server" Text='<%# DataBinder.Eval(Container, "DataItem.LastName") %>' OnTextChanged="javascript:this.parentElement.children(0).checked=true;">
Line 36: </asp:TextBox>
Line 37: </ItemTemplate>
TextBox txt1=(TextBox)e.Item.FindControl("TextBox1");
txt1.Attributes.Add("OnTextChanged","javascript:this.parentElement.children(0).checked=true;");
txt1.Attributes.Add("onchange ","javascript:this.parentElement.children(0).checked=true;");