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: November 16, 2018).
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

How to check a CheckBox programmatically?

Thread ID:





128959 Feb 17,2017 04:12 PM UTC Feb 20,2017 01:03 PM UTC ASP.NET MVC 1
Tags: Checkbox
Cornel Amarandei
Asked On February 17, 2017 04:12 PM UTC


I have a CheckBox like this:


I want to check this CheckBox programmatically from the client side(so to change to true the Checked property).


sureshkumar.P [Syncfusion]
Replied On February 20, 2017 01:03 PM UTC

Hi Cornel, 
Thanks for contacting Syncfusion support, 
You can dynamically change the property value from code behind by creating instance of  the control. To showcase this, here we have changed the CheckBox “checked” property(API) value programmatically using the toggleButton’s client side change event 
Please refer the below code sample 
var btnObj; 
        $(document).ready(function () { 
            btnObj = $("#CheckBoxRefreshed").data("ejCheckBox"); 
function tglebtnChange(e) {  //toggleButton’s client side Change event 
        //checkbox object (instance) creation to access the checkbox propertyies 
        if (e.isChecked) 
            btnObj.option("checked", true);  // change the checked property as true by using checkbox object 
            btnObj.option("checked", false); // change the checked property as false by using checkbox object 
For your convenience, we have created a sample to change the CheckBox state’s by using ToggleButton’s client side event http://www.syncfusion.com/downloads/support/forum/128959/ze/CheckBox_ClientSideEvent-952065350  
To know more about checkbox API, Events and Methods using below link: https://help.syncfusion.com/api/js/ejcheckbox  
Sureshkumar P 


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.

Please sign in to access our forum

or the page will be automatically redirected to sign-in page in 10 seconds.

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