We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. (Last updated on : Nov 16th 2018).
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

Button OnClick event is not work and how to set validation for maskedit control on button click

Thread ID:

Created:

Updated:

Platform:

Replies:

121182 Nov 17,2015 05:08 PM UTC Dec 9,2016 11:34 AM UTC ASP.NET Web Forms 5
loading
Tags: Button
Badal Patel
Asked On November 17, 2015 05:08 PM UTC

Hi,
I am new to syncfusion. I have issue with the control. Please help me. I have simple contact form which is having name, email and message text box. I want to set required validation as well as for email validation. If validation does not fulfilled than button click with not work.
I also set button OnClick event. I also written code on button click in code behind. But OnClick is not work. So please help me out with these issue. Please check my code which is written below:

Contact

  • Code behind code
    protected void btnSendEmail_Click(object Sender, Syncfusion.JavaScript.Web.ButtonEventArgs e)
    {
    if (txtEmail.Value.Trim() != string.Empty && txtName.Value.Trim() != string.Empty && txtMessage.Value.Trim() != string.Empty)
    {
    string Message = SendEmail();
    }
    }

    Arun Palaniyandi [Syncfusion]
    Replied On November 19, 2015 09:22 AM UTC


    Hi Badal


    Thanks for the update,


    We were unable to reproduce the issue, “Button OnClick event is not work” by the given code. From our end, the given code is working perfectly and the OnClick event is also working for the sample. We have also provided the video demo for the corresponding sample.

    Please find the video in the below link.

    http://www.syncfusion.com/downloads/support/forum/121182/ze/demo613030923


    We have also attached the sample by setting the required field validation.

    http://www.syncfusion.com/downloads/support/forum/121182/ze/ButtonnewSample1973384606


    Please share the screenshots of the corresponding error , so that we will help you. 


    Regards,

    Arun P


    Badal Patel
    Replied On November 19, 2015 12:26 PM UTC

    Hi Arun,

    Thank you for quick response.

    I download your source code. I open it and run it. but click event is not working in it.

    Arun Palaniyandi [Syncfusion]
    Replied On November 20, 2015 12:16 PM UTC

    Hi Badal,

    Thanks for the  update,

    Please log on to our support website to check for further updates on the reported issue.

    https://www.syncfusion.com/account/login?ReturnUrl=%2fsupport%2fdirecttrac%2fincidents

    Please let me know if you have any questions.

    Regards,
    Arun P

    Wiseman
    Replied On December 8, 2016 09:24 AM UTC

    Did you find any solution for the above problem I am also having the same problem, I did try those sample it also not working.

    Francis Paul Antony Raj [Syncfusion]
    Replied On December 9, 2016 11:34 AM UTC

    Hi Wiseman, 
     
    Usually, the server-side event might not be triggered due to one of the following reasons. So, please check the below references in your page. 

    1. Please check
    asp:ScriptManager is referred in your ‘Site.Master’ page.
    2. Please check
    ej.webform.min.js file is referred at the end of the script section as given below. 
     
    [Site.Master] 
    <head runat="server"> 
    <%: Scripts.Render("~/Scripts/jquery-1.10.2.min.js")%>  
    <%: Scripts.Render("~/Scripts/jsrender.min.js")%>  
    <%: Scripts.Render("~/Scripts/ej/ej.web.all.min.js")%>  
    <%: Scripts.Render("~/Scripts/ej/ej.webform.min.js")%> 
    </head> 
    <body> 
        <form runat="server"> 
            <asp:ScriptManager runat="server"> 
                 
            </asp:ScriptManager> 
            <!--Other Codes--> 
       </form> 
    </body>  
    We have explained the necessity to refer the above mentioned references in our help document under Adding required Script files section.
    https://help.syncfusion.com/aspnet/getting-started#adding-required-script-files 

    Regards, 
    Francis Paul A. 


    CONFIRMATION

    This post will be permanently deleted. Are you sure you want to continue?

    Sorry, An error occured while processing your request. Please try again later.

    Warning Icon You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.Close Icon

    ;