Event delay / catch event and execute manually ...

Hi,

I can veto an event to stop processing it via event.Veto()

Now I want to do something BEFORE processing an event. (not veot it but
'postpone' it 'til i am done w/ other things I start)

In my particular case I need to get things from a panel and its window
reference before closing it.
I am displaying a dialog before closing and if the closing is confirmed I
see that the 1st thing that happens is that the panel object gets deleted.
The panel object resides as a key (not as strg(key)) in a dictionary I
need to work on BEFORE the panel gets deleted.
The way it is working now I end up with a dictionary I cannot access
anymore by key because the key (i.e. the panel object) was deleted right
on confirmation ...

Looking fwd to any suggestion ...

···

--
--------------------------------------------------
Tobias Weber
CEO

The ROG Corporation GmbH
Donaustaufer Str. 200
93059 Regensburg
Tel: +49 941 4610 57 55
Fax: +49 941 4610 57 56

www.roglink.com

Geschï¿œftsfï¿œhrer: Tobias Weber
Registergericht: Amtsgericht Regensburg - HRB 8954
UStID DE225905250 - Steuer-Nr.184/59359
--------------------------------------------------

Do whatever you need to do after the dialog's ShowModal returns and before you do whatever you do that causes the panel to be be destroyed.

···

On 11/11/11 9:30 AM, Tobias Weber wrote:

Hi,

I can veto an event to stop processing it via event.Veto()

Now I want to do something BEFORE processing an event. (not veot it but
'postpone' it 'til i am done w/ other things I start)

In my particular case I need to get things from a panel and its window
reference before closing it.
I am displaying a dialog before closing and if the closing is confirmed I
see that the 1st thing that happens is that the panel object gets deleted.
The panel object resides as a key (not as strg(key)) in a dictionary I
need to work on BEFORE the panel gets deleted.
The way it is working now I end up with a dictionary I cannot access
anymore by key because the key (i.e. the panel object) was deleted right
on confirmation ...

Looking fwd to any suggestion ...

--
Robin Dunn
Software Craftsman