Add, Edit & Delete Notification

Add, Edit & Delete Notification

Old forum URL: forums.lhotka.net/forums/t/3942.aspx


CSLAer posted on Monday, November 26, 2007

Hi,

I have a read-only list at the selection form. After select one record, it loads the editable record and goes to another form to edit. I can use editable record.Saved+=new ......to capture the event and reload the read-only list for Add and Edit (I have to change the tem.Save() to record.Save()), however I found it's difficult for record deletion. I use Record.DeleteRecord(Id) to delete record at the selection form. Is there any one can help me?

Thanks

robert_m replied on Tuesday, November 27, 2007

If your edit form is modal, then you could simply use DialogResult to find out what happened.

Like this:

DialogResult result = editFrm.ShowDialog();

if (result != DialogResult.Cancel)

     doRefresh();

Looks simpler to me...

 

CSLAer replied on Tuesday, November 27, 2007

robert_m:

If your edit form is modal, then you could simply use DialogResult to find out what happened.

Like this:

DialogResult result = editFrm.ShowDialog();

if (result != DialogResult.Cancel)

     doRefresh();

Looks simpler to me...

Thanks for your information. But I'm not using modal form, I want to use a more elegant way to do this with Saved event.

Copyright (c) Marimer LLC