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

[Solved] GridView.BeginInsert() does not work when no data in grid

1 Answer 115 Views
GridView
This is a migrated thread and some comments may be shown as answers.
This question is locked. New answers and comments are not allowed.
Mike
Top achievements
Rank 1
Mike asked on 18 Jan 2011, 06:39 AM
Hi,

I have a GridView into which I'm allowing the user to insert rows.  This works perfectly if the datasource to which it is bound already contains items - in other words, when the user can see data in the grid, then calling the BeginInsert method works correctly.

But if the grid is empty, then calling BeginInsert() seems to have no effect.  I have tried both hooking a button up to call the BeginInsert() method (in which, if I set a breakpoint, I can see the method being called), and also by using the Insert key.  When the grid is populated, a blank row is inserted correctly, but when empty, nothing happens.

What am I doing wrong?

1 Answer, 1 is accepted

Sort by
0
Maya
Telerik team
answered on 18 Jan 2011, 08:59 AM
Hi Mike,

I was not able to reproduce the issue you specified. I am sending you the sample project I used for testing it. Please take a look at it and let me know in case of any misunderstandings.
 

Regards,
Maya
the Telerik team
Let us know about your Windows Phone 7 application built with RadControls and we will help you promote it. Learn more>>
Tags
GridView
Asked by
Mike
Top achievements
Rank 1
Answers by
Maya
Telerik team
Share this question
or