Enable RadButton whe a colum is checked on a RadGridView

2 posts, 0 answers
  1. Hola
    Hola avatar
    3 posts
    Member since:
    Nov 2011

    Posted 24 Nov 2011 Link to this post


    I am trying to enable a Buttom when somebody check a column on a RadGridView ...

    it is the classic example of delete row ... I want to enable the delete buttom when somebody check at least one row in the grid.

    Here is my code:

    <telerik:RadButton Margin="2" Name="deleteApplicationButton" Click="deleteApplicationButton_Click" IsEnabled="False">
                               <Image Source="component/Resources/tool_bar_delete.png" Stretch="None" ToolTipService.ToolTip="New Application" />
                       <telerik:RadGridView Grid.Row="1"                                         
                                            ItemsSource="{Binding Path=Applications, Mode=TwoWay, UpdateSourceTrigger=PropertyChanged}" 
                               <telerik:GridViewCheckBoxColumn Header="Delete" DataMemberBinding="{Binding Path=IsChecked}"></telerik:GridViewCheckBoxColumn>
                              <!-- <telerik:GridViewDataColumn Header="Disable" DataMemberBinding="{Binding Path=Disable}" /> -->
                               <telerik:GridViewDataColumn Header="Name" DataMemberBinding="{Binding Path=Key}"  IsReadOnly="True" />
                               <telerik:GridViewDataColumn Header="Description" DataMemberBinding="{Binding Path=Description}" Width="*" IsReadOnly="False" />
                               <telerik:GridViewDataColumn IsVisible="False" Header="GUID" DataMemberBinding="{Binding Path=GUID}" Width="*" IsReadOnly="False" />                            

    Please, how can I do it ... Could anybody provide a simple example?

    Thanks a lot
  2. Petar Mladenov
    Petar Mladenov avatar
    2991 posts

    Posted 29 Nov 2011 Link to this post

    Hi Hola,

     Please check out the attached project where a basic approach is realized. Feel free to ask if you need further assistance. 

    Best wishes,
    Petar Mladenov
    the Telerik team

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

Back to Top