I have a Silverlight UserControl with a Telerik RadGridView control and a handful of button controls. The problem is that when I edit a cell in the grid view and then click any of the buttons the button command does not execute until; the button is selected a second time. The first press seems to remove the focus from the RadGridView and second succeeds in firing the bound command. Obviously, this makes for a terrible user interface. Does anyone know what might be going on here?
With the exception of the UI behavior everything else works fine.
Simplified XAML:
<StackPanel Orientation="Horizontal">
开发者_运维百科<Button Content="Save" Command="{Binding SaveCommand}" />
<Button Content="Close" Command="{Binding CloseCommand}" />
</StackPanel>
<telerik:RadGridView ItemsSource="{Binding StockItems,Mode=TwoWay}"
AutoGenerateColumns="False"
IsFilteringAllowed="False"
ShowGroupPanel="False">
<telerik:RadGridView.Columns>
<telerik:GridViewDataColumn DataMemberBinding="{Binding LabelGroup,Mode=TwoWay}"
Header="Label Group" />
<telerik:GridViewDataColumn DataMemberBinding="{Binding Message,Mode=TwoWay}"
Header="Message" />
</telerik:RadGridView.Columns>
</telerik:RadGridView>
Thanks in advance, Jim
The problem is already fixed - you can check this thread for more info: http://www.telerik.com/community/forums/silverlight/gridview/why-do-we-need-to-click-twice-on-a-button-within-a-radgridview.aspx
精彩评论