Checkbox not updating OnInitializedAsync

SfCheckBox, how to load bind UI with initial value, wont bind in the UI on first render, then when you click the check box you have to click it twice for it to set it to checked the first time?
Running in the following way, I have a blazor page, and in this page I reference a razor component, which has all the sf components of the form.

1 Reply

SD Saranya Dhayalan Syncfusion Team May 22, 2020 10:23 AM UTC

Hi Raul, 
 
Thank you for contacting Syncfusion support 
 
We have checked your reported query, you can achieve this in checkbox created event. Please find the below code snippet: 
 
@using Syncfusion.Blazor.Buttons 
 
<SfCheckBox  @bind-Checked="@iCch"  Created="onCreated"></SfCheckBox> 
 
 
@code{ 
 
    public bool iCch { get; set; } 
 
 
    public void onCreated() 
    { 
        iCch = true; 
    } 
 
} 
 
 
 
Query: when you click the check box you have to click it twice for it to set it to checked the first time? 
 
We have checked your reported query, we would like to let you know the following details 
 
1.       Please provide any other customization done in the sample level. 
 
2.       Please provide your razor page. 
 
Please provide the above requested information, based on that we will check and provide you a better solution quickly. 
 
Regards, 
Saranya D 


Loader.
Up arrow icon