SOLVED: Problem cleaning up |
Post Reply |
Author | |
rdhaan
Newbie Joined: 11 December 2008 Location: Netherlands Status: Offline Points: 7 |
Post Options
Thanks(0)
Posted: 20 January 2009 at 9:02am |
Hi all,
I have a problem with cleaning up the Panes.
I create 3 panes , with 1 docked to the right, and the other 2 below the first.
ASSIGN h_Pane = ch_DockingPane:CreatePane( 1, 150, 100, 1 /* Right */, ? ).
ASSIGN h_Pane = ch_DockingPane:CreatePane( 2, 150, 100, 3 /* Bottom */, h_Pane ). ASSIGN h_Pane = ch_DockingPane:CreatePane( 3, 150, 100, 3 /* Bottom */, h_Pane ). /* Use them */
then for the first 2 i create a frame and set the handle (third is not used at this moment, still developing).
After the program is done, i want to clean it all up:
/* Clean up */ DO WHILE ch_DockingPane:PanesCount > 0: ASSIGN h_Pane = ch_DockingPane:FindPane( ip_ID ). IF NOT VALID-HANDLE( h_Pane ) THEN next. MESSAGE 'Cleaing up number: ' h_Pane:ID.
ch_DockingPane:DestroyPane( h_Pane ).
END. But: I get the message 'Cleaing up number 3:' and then my applicatyion crashes.
What do i do wrong?
BTW. This is written in Openedge, but using the same kind of code in VB also crashes VB????
|
|
Oleg
Admin Group Joined: 21 May 2003 Location: United States Status: Offline Points: 11234 |
Post Options
Thanks(0)
|
Hi, Guess you call DestroyPane for same pane twice. Please attach this VB sample that crash
|
|
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS |
|
rdhaan
Newbie Joined: 11 December 2008 Location: Netherlands Status: Offline Points: 7 |
Post Options
Thanks(0)
|
Hoi Oleg,
I've found out what my problem was.
First my window is destroyed (and effectly set the hwnd to 0...).
then i start deleting my panes and all frames and windows atteched to them. This results in the crash.
I made the VB by hand, resulting in the same situation: frst the window is destroyed, then the pane(s).
After changing the order (first the pane, then the window) the problem is solved.
|
|
Post Reply | |
Tweet
|
Forum Jump | Forum Permissions You cannot post new topics in this forum You cannot reply to topics in this forum You cannot delete your posts in this forum You cannot edit your posts in this forum You cannot create polls in this forum You cannot vote in polls in this forum |