我是 asp.net 的新手,我正在设置必填字段验证器,它向我显示一个错误
错误是:
Unable to find control id 'txtFirstName' referenced by the 'ControlToValidate' property of 'RequiredFieldValidator1'.
代码是:
<tr>
<td align="right" style="padding-right: 5px; width: 50%;">
<asp:Label ID="lblFirstName" runat="server" Text="FIRSTNAME :"></asp:Label>
</td>
<td align="left" style="padding-left: 5px; width: 50%;">
<asp:TextBox ID="txtFistName" runat="server" Width="70%"></asp:TextBox>
<asp:RequiredFieldValidator ID="RequiredFieldValidator1" runat="server" ControlToValidate="txtFirstName" ErrorMessage="You can't leave this empty."></asp:RequiredFieldValidator>
</td>
</tr>
任何人都可以在这个流程上帮助我......,