1.In Web.config file
in handlers section
2.Add Captcha DLL to AddReferences
3.Aspx
<%@ Register Assembly="MSCaptcha" Namespace="MSCaptcha" TagPrefix="cc1" %>
cc1:CaptchaControl ID="CaptchaControl1" runat="server"
asp:Label ID="lbltext" Text="enter the above code here:" runat="server
asp:TextBox ID="txtCaptch" runat="server"
asp:Label ID="lblmessage" runat="server"
4.in button click write(Aspx.cs)
if (!CaptchaControl1.UserValidated)
{
lblmessage.Text = "You Enterted Text Doesn't Match";
return;
}
else
{
lblmessage.Text = "Secuessfully entered";
CaptchaControl1.Visible = false;
txtCaptch.Visible = false;
lbltext.Visible = false;
lblmessage.Visible = false;
}
in handlers section
2.Add Captcha DLL to AddReferences
3.Aspx
<%@ Register Assembly="MSCaptcha" Namespace="MSCaptcha" TagPrefix="cc1" %>
cc1:CaptchaControl ID="CaptchaControl1" runat="server"
asp:Label ID="lbltext" Text="enter the above code here:" runat="server
asp:TextBox ID="txtCaptch" runat="server"
asp:Label ID="lblmessage" runat="server"
4.in button click write(Aspx.cs)
if (!CaptchaControl1.UserValidated)
{
lblmessage.Text = "You Enterted Text Doesn't Match";
return;
}
else
{
lblmessage.Text = "Secuessfully entered";
CaptchaControl1.Visible = false;
txtCaptch.Visible = false;
lbltext.Visible = false;
lblmessage.Visible = false;
}
Comments
Post a Comment