Hi,
I have a problem using "paste" in radgridView of 2012.2.607.40. (it Works well of 2011.3.1116.40).
I select 3 rows in Excel,copy them and I want to paste these in my grid. I click new row then click paste. I hope that the 3 rows will in the last 3 rows in my grid. it means that these 3 rows will be 3 new rows of my grid. BUT the result is , it will erase the first 3 rows of my current grid. Sometimes il will erasing the last few rows.
For exemple : I have 1,2,3,4 in my grid, each number in a different row (4 rows). Now, i want to paste 5,6,7 in the grid, I click add rows (now I have 1,2,3,4,0 in 5 rows), and click paste, the result that I want is 1,2,3,4,5,6,7, BUT the result is 5,6,7,4,0 .
Here is my grid :
<telerik:RadGridView
SelectionMode="Extended" MaxHeight="150" x:Name="gridView"
IsReadOnly="{Binding Path=ObjectBase.IsReadOnly, RelativeSource={RelativeSource FindAncestor, AncestorType=sc:GridDesigner}}"
VerticalAlignment="Top" CanUserDeleteRows="True" RowIndicatorVisibility="Visible"
CanUserFreezeColumns="False" CanUserInsertRows="True" ShowGroupPanel="False"
AutoGenerateColumns="True" CanUserSelect="True" SelectionUnit="FullRow"
ClipboardCopyMode="Cells" ClipboardPasteMode="Default" BorderThickness="0" EnableRowVirtualization="True">
</telerik:RadGridView>
Then I have tried to use the control of Pasting like this :
private void gridView_Pasting(object sender, GridViewClipboardEventArgs e)
{
var newItem = this.radGridView1.Items.AddNew();
this.gridView.SelectedItem = newItem;
}
And also like this:
private void gridView_Pasting(object sender, Telerik.Windows.Controls.GridViewClipboardEventArgs e)
{
this.gridView.Items.MoveCurrentToLast();
}
but it doesn't work.
Thank you in advance for your help.
Ricardo Chorro.
I have a problem using "paste" in radgridView of 2012.2.607.40. (it Works well of 2011.3.1116.40).
I select 3 rows in Excel,copy them and I want to paste these in my grid. I click new row then click paste. I hope that the 3 rows will in the last 3 rows in my grid. it means that these 3 rows will be 3 new rows of my grid. BUT the result is , it will erase the first 3 rows of my current grid. Sometimes il will erasing the last few rows.
For exemple : I have 1,2,3,4 in my grid, each number in a different row (4 rows). Now, i want to paste 5,6,7 in the grid, I click add rows (now I have 1,2,3,4,0 in 5 rows), and click paste, the result that I want is 1,2,3,4,5,6,7, BUT the result is 5,6,7,4,0 .
Here is my grid :
<telerik:RadGridView
SelectionMode="Extended" MaxHeight="150" x:Name="gridView"
IsReadOnly="{Binding Path=ObjectBase.IsReadOnly, RelativeSource={RelativeSource FindAncestor, AncestorType=sc:GridDesigner}}"
VerticalAlignment="Top" CanUserDeleteRows="True" RowIndicatorVisibility="Visible"
CanUserFreezeColumns="False" CanUserInsertRows="True" ShowGroupPanel="False"
AutoGenerateColumns="True" CanUserSelect="True" SelectionUnit="FullRow"
ClipboardCopyMode="Cells" ClipboardPasteMode="Default" BorderThickness="0" EnableRowVirtualization="True">
</telerik:RadGridView>
Then I have tried to use the control of Pasting like this :
private void gridView_Pasting(object sender, GridViewClipboardEventArgs e)
{
var newItem = this.radGridView1.Items.AddNew();
this.gridView.SelectedItem = newItem;
}
And also like this:
private void gridView_Pasting(object sender, Telerik.Windows.Controls.GridViewClipboardEventArgs e)
{
this.gridView.Items.MoveCurrentToLast();
}
but it doesn't work.
Thank you in advance for your help.
Ricardo Chorro.