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

Problem of adding blank row on <Insert> Key pressed from keyboard

2 Answers 68 Views
GridView
This is a migrated thread and some comments may be shown as answers.
Gurpreet Singh
Top achievements
Rank 1
Gurpreet Singh asked on 03 Feb 2012, 07:41 AM

 

 

 

Hi,
I am using RadGridView control, getting an issue with it. when I am preesing <Insert> key from Keyboard then it adds a new blank row in RadGridView control.

I want it should  not be added, with that <Insert> key from the keyboard.  Code is given below for refrence. thanks in advance

<telerik:RadGridView x:Name="GridTasks" CanUserSortColumns="False" IsFilteringAllowed="False" Width="Auto" VerticalAlignment="Top" AutoGenerateColumns="False" ShowColumnFooters="False"
                 ItemsSource="{Binding InvoiceTasks}" SelectedItem="{Binding SelectedTask, Mode=TwoWay}"
                 SelectionChanged="GridTasks_SelectionChanged"
                 GotFocus="GridTasks_GotFocus"
                 LostFocus="GridTasks_LostFocus"
                 SelectionMode="Single" SelectionUnit="FullRow" telerik:StyleManager.Theme="{StaticResource EditableGridTheme}" DataLoaded="GridTasks_DataLoaded">
  <telerik:RadGridView.Columns>
    <telerik:GridViewColumn UniqueName="img" Width="33">
      <telerik:GridViewColumn.CellTemplate>
        <DataTemplate>
          <ContentControl IsEnabled="False"  Content="{Binding Converter={StaticResource WorkFlowImageConverter}}"></ContentControl>
        </DataTemplate>
      </telerik:GridViewColumn.CellTemplate>
    </telerik:GridViewColumn>
       
    <telerik:GridViewDataColumn DataMemberBinding="{Binding Created,StringFormat='dd.MM.yyyy HH:mm'}"
                                EditTriggers="None" IsReadOnly="True"
                                Header="{Binding Path=Localizer[IA.Views.WorkflowPage.TaskGridHeader_Created], Source={StaticResource Localizations}}"
                                UniqueName="CreatedDate" Width="*"/>
  </telerik:RadGridView.Columns>
</telerik:RadGridView>

 

 

 

 

 


Thanks,
Gurpreet

 

2 Answers, 1 is accepted

Sort by
0
Gurpreet Singh
Top achievements
Rank 1
answered on 06 Feb 2012, 05:10 AM
Hello,
Still getting same problem, and waiting for response,

Please reply.


Thanks
Gurpreet
0
Maya
Telerik team
answered on 06 Feb 2012, 07:37 AM
Hi Gurpreet,

If you want to predefine the  default keyboard behavior, you can create your own custom keyboard command provider.
Please refer to our online documentation and blog posts for a reference.

All the best,
Maya
the Telerik team
Sharpen your .NET Ninja skills! Attend Q1 webinar week and get a chance to win a license! Book your seat now >>
Tags
GridView
Asked by
Gurpreet Singh
Top achievements
Rank 1
Answers by
Gurpreet Singh
Top achievements
Rank 1
Maya
Telerik team
Share this question
or