This is a migrated thread and some comments may be shown as answers.

Checked RadRadioButton Visualisation after Re-Enabling

8 Answers 252 Views
Buttons
This is a migrated thread and some comments may be shown as answers.
This question is locked. New answers and comments are not allowed.
Jani
Top achievements
Rank 1
Jani asked on 19 Nov 2009, 08:38 AM
I have a RadRadioButton which is checked (IsChecked=true).
The RadRadioButton is child of an MS Activity Control, which disables/enables all child control during long operations.
After Re-Enabling the RadRadioButton, it will be rendered like an unchecked button (The property IsChecked is still true).
It seems to be an theme issue...

Cheers,
Jani

8 Answers, 1 is accepted

Sort by
0
Kiril Stanoev
Telerik team
answered on 19 Nov 2009, 04:17 PM
Hello Jani,

Thank you for reporting this issue. Indeed it is a theming issue. I have logged it and we will try to fix it for our Service Pack 1 release. I have also added 1000 Telerik points to your account.

Sincerely yours,
Kiril Stanoev
the Telerik team

Instantly find answers to your questions on the new Telerik Support Portal.
Watch a video on how to optimize your support resource searches and check out more tips on the blogs.
0
Jason
Top achievements
Rank 1
answered on 09 Feb 2012, 04:20 AM

From what I can tell this is still a bug.  I did find a work-around to this issue.  After I re-enable my controls, including the RadRadioButton, I uncheck the "checked" item then check it again.  This seems to force the button to be checked after the control is no longer disabled.  Here is a code snippet of what worked for me.  Thanks!

if (myObject.IsAnswerYes == true)
{
    chkAnswerYes.IsChecked = false;
    chkAnswerYes.IsChecked = true;
}
else
{
    chkAnswerNo.IsChecked = false;
    chkAnswerNo.IsChecked = true;
}

0
Zarko
Telerik team
answered on 13 Feb 2012, 07:02 PM
Hi,
Thank you for the feedback. I'm glad to tell you that this bug is already fixed and the fix will be available in our next major release - Q1 2012 later this week.
If you have more questions please don't hesitate to ask.

Regards,
Zarko
the Telerik team
Sharpen your .NET Ninja skills! Attend Q1 webinar week and get a chance to win a license! Book your seat now >>
0
Valeriu
Top achievements
Rank 1
answered on 07 May 2012, 04:02 PM

Can you confirm that this issue is fixed in current release?

I have in my code:

  <telerik:RadToggleButton IsChecked="{Binding IsActive}"

And it doesn't change it's visual state when IsActive flag is updated from my view model.

0
Zarko
Telerik team
answered on 10 May 2012, 02:10 PM
Hello Valeriu,
As far as we know this issue is fixed and it should be working. Could you please send us some code snippets or a sample project which shows the problem because I wasn't able to recreate it?
I've attached the sample project that I used for testing so you could examine it and see it helps you.
We're looking forward to hearing from you.

Greetings,
Zarko
the Telerik team

Explore the entire Telerik portfolio by downloading the Ultimate Collection trial package. Get it now >>

0
Rob Ainscough
Top achievements
Rank 1
answered on 09 Nov 2012, 10:53 PM
I'm having the same problem in build 2012.2.725.1050.

I have IsChecked bound to my ViewModel like so:

<telerik:RadRadioButton x:Name="PercentRadioButton" Grid.Column="2" Grid.Row="0" Content="%" FontWeight="ExtraBold" IsChecked="{Binding Path=IsPercent, Mode=TwoWay}" GroupName="AmountPercentGroup" Padding="1,1,1,3">
</telerik:RadRadioButton>

ViewModel

Public Class UIAmountPercentRadioButtons
    Implements INotifyPropertyChanged, IDataErrorInfo
 
    Public Event PropertyChanged As PropertyChangedEventHandler Implements INotifyPropertyChanged.PropertyChanged
    Public Sub OnPropertyChanged(ByVal e As PropertyChangedEventArgs)
 
        If PropertyChangedEvent IsNot Nothing Then
 
            Select e.PropertyName
 
                Case Else
 
            End Select
 
        End If
 
    End Sub
 
    Private _IsPercent As Boolean
    Public Property IsPercent() As Boolean
        Get
            Return _IsPercent
        End Get
        Set(ByVal value As Boolean)
            _IsPercent = value
            OnPropertyChanged(New PropertyChangedEventArgs("IsPercent"))
        End Set
    End Property

If I set Me.IsPercent = True in a method in my ViewModel the UI radRadioButton visual state "unchecked".

Was this bug fixed in a later build??  Not that it matters because your most recent build has bugs that prevent me from using it also.

Rob.

0
Zarko
Telerik team
answered on 14 Nov 2012, 01:07 PM
Hi Rob,
Could you please try add this code in your ViewModel's OnPropertyChanged method:
Select Case e.PropertyName
    Case Else
    RaiseEvent PropertyChanged(Me, New PropertyChangedEventArgs(e.PropertyName))
End Select
After this everything should be working fine.
I've attached the sample project that I used for testing so could you please examine it and if you have further questions feel free to ask.

Regards,
Zarko
the Telerik team

Explore the entire Telerik portfolio by downloading Telerik DevCraft Ultimate.

0
Rob Ainscough
Top achievements
Rank 1
answered on 14 Nov 2012, 10:58 PM
Zarco,

Thanks, got it sorted.  The RadRadioButton is working fine -- my the an object Instance in my VM was be re-initialized and hence the binding value also.

Rob 
Tags
Buttons
Asked by
Jani
Top achievements
Rank 1
Answers by
Kiril Stanoev
Telerik team
Jason
Top achievements
Rank 1
Zarko
Telerik team
Valeriu
Top achievements
Rank 1
Rob Ainscough
Top achievements
Rank 1
Share this question
or