hi
I have 2 image button and 4 RequiredFieldValidator on page
I want when I click on the ImageSend button just RFV1 and RFV2 work and show error for these two validators and if I click on ImageInfo RFV3 and RFV4 will work and show an error
I mean I want to put different validator for different button
<asp:RequiredFieldValidator Display="Dynamic" ID="RFV1" runat="server" ControlToValidate="TxtejareM"></asp:RequiredFieldValidator>
<asp:RequiredFieldValidator Display="Dynamic" ID="RFV2" runat="server" ControlToValidate="TxtvadieM"></asp:RequiredFieldValidator>
<asp:RequiredFieldValidator Display="Dynamic" ID="RFV3" runat="server" ControlToValidate="TxtnameM"></asp:RequiredFieldValidator>
<asp:RequiredFieldValidator Display="Dynamic" ID="RFV4" runat="server" ControlToValidate="TxtmobileM"></asp:RequiredFieldValidator>
<asp:ImageButton ID="ImageSend" runat="server" CssClass="sendInfoM" ImageUrl="~/Image/main/sendinfo.png" OnClick="ImgsendSend_Click" OnClientClick="ValidateM()"></asp:ImageButton>
<asp:ImageButton ID="ImageInfo" runat="server" CssClass="sendInfoM" ImageUrl="~/Image/main/info.png" OnClick="Imgsendinfo_Click" OnClientClick="Validate()"></asp:ImageButton>
How I can do it?
Best regards
Neda