New Posts New Posts RSS Feed: Topic Add-Delete on Child Grid example not working
  FAQ FAQ  Forum Search   Calendar   Register Register  Login Login

Topic Add-Delete on Child Grid example not working

 Post Reply Post Reply
Author
Dominique View Drop Down
Groupie
Groupie
Avatar

Joined: 28-Jun-2007
Location: Norway
Posts: 44
Post Options Post Options   Quote Dominique Quote  Post ReplyReply Direct Link To This Post Topic: Topic Add-Delete on Child Grid example not working
    Posted: 22-Oct-2007 at 1:44am
Hi,
I remember having problems with that example too. As far as I remember the UserDeletingRow event is not fired because the Child-list is readonly.
Another drawback is that it is possible to add many row to the collection without seiing them (playing with the up, down key for example)

The easiest way I found to have the default dotnet grid behaviour was to use a list for the details grid and to update the binding on the MasterBindingSource.CurrentChanged event.


Dominique
Dominique
Back to Top
IDelgado View Drop Down
Newbie
Newbie


Joined: 04-Oct-2007
Posts: 5
Post Options Post Options   Quote IDelgado Quote  Post ReplyReply Direct Link To This Post Posted: 05-Oct-2007 at 7:43am

The example i'm refering it's the one that shows the way to delete  an object by selecting its row and pressing the DEL key, i'm using VB NET 2005 and the .NET grid.

This is the code in the example mentioned:

  Private Sub OrdersDGV_UserDeletingRow( _

ByVal sender As Object, _

      ByVal e As System.Windows.Forms.DataGridViewRowCancelEventArgs)

    OrderDelete(CType(e.Row.DataBoundItem, Order))

    e.Cancel = True

  End Sub

Back to Top
davidklitzke View Drop Down
IdeaBlade
IdeaBlade
Avatar

Joined: 14-Jun-2007
Posts: 715
Post Options Post Options   Quote davidklitzke Quote  Post ReplyReply Direct Link To This Post Posted: 04-Oct-2007 at 10:56pm
There are many code examples in 216 Add-Delete on Child Grid.  Which code example or tutorial are you referring to?
 
Are you using .NET, DevForce, or Infragistics grid?
 
If DevExpress or Infragistics, what version are you using?


Edited by davidklitzke - 04-Oct-2007 at 10:58pm
Back to Top
IDelgado View Drop Down
Newbie
Newbie


Joined: 04-Oct-2007
Posts: 5
Post Options Post Options   Quote IDelgado Quote  Post ReplyReply Direct Link To This Post Posted: 04-Oct-2007 at 4:49pm
Hi,
I tried the example in the topic 216 Add-Delete on Child Grid, try to delete a row in the grid using the DEL key but nothing happens. The userdeletingrow event never fires. What can be wrong? I have the same situation in my app, so i'd like to know what is missing here.
Thanks.
 
Back to Top
 Post Reply Post Reply

Forum Jump Forum Permissions View Drop Down