Styled RadioButton Checked/Unchecked error

Please post public support tickets here. Note: for private support tickets, please send an email to support@cshtml5.com instead.
fangeles
Posts: 38
Joined: Wed Jan 16, 2019 12:48 am

Styled RadioButton Checked/Unchecked error

Postby fangeles » Tue Jul 02, 2019 7:40 pm

Hi JS-Support team,

I am customizing the appearance of controls, in this case the RadioButton, I have followed the instructions to use the ToggleButton style template (not mentioned for radio button but for check boxes, however it works) but when the page loaded, the checked and unchecked status is not respected.

Scenario: there's a conditional statement on c# that checks a specific checkbox.

Code: Select all

if(value == 1)
{
    RadioButton1.Checked = true;
}


But when I select another radio button from that radio butto group (contained in WrapPanel), the RadioButton is still checked. But when I clicked the Checked RadioButton first, it behaves normally.

Please see my sample video below (Uploaded to OneDrive)
https://1drv.ms/v/s!AmXRQIT1e96EmrlRwV32rrDchRE2QA?e=wkjIRx


Hoping for your feedback.

Thanks.

JS-Support @Userware
Site Admin
Posts: 1093
Joined: Tue Apr 08, 2014 3:42 pm

Re: Styled RadioButton Checked/Unchecked error

Postby JS-Support @Userware » Fri Jul 12, 2019 3:34 am

Hi,

Thanks for your message.

A "styles kit" will be released in the coming weeks that shows how to style each control. Could you please check again with those styles when they are available?

They will be added to the Showcase app at:
https://github.com/cshtml5/CSHTML5.Samples.Showcase

Thanks
Regards

MichaelHughes
Posts: 28
Joined: Thu Oct 08, 2015 5:33 am

Re: Styled RadioButton Checked/Unchecked error

Postby MichaelHughes » Tue Nov 12, 2019 5:46 am

Hi

I had a similar problem - I assumed it was my code (it still might be)

I found the first couple of times the radio button in a group didn't honour the settings.

Setting the first one off and on a couple of times seemed to clear the issue and the group responded as expected. (nasty but it worked for me) - I've just remembered I didn't report it.

It might be worth doing the same thing before attaching the relevant event to see if that helps - I do it by creating button collapsed change checked status a few times put it back to the state I want and then attach the events and then it seems to proceed as expected


Return to “Technical Support”

Who is online

Users browsing this forum: No registered users and 5 guests

 

 

cron