Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Proper Way to Close Parent Window from User Object

Status
Not open for further replies.

power97

Programmer
Sep 17, 2003
67
CA
Hi,
I have some user objects ( inherited from u_tabpg ) that are tab pages that fire code in the constructor on the datawindow ( contained on the user object ) . However , if something fails I would like to close the parent window. I am doing the following:

w_master lw1
this.of_GetParentWindow(lw_lw1)
lw_lw1.TriggerEvent("pfc_close")

However , I'm not sure if this is the correct way or if there is a better way. Also , I'm not sure if it's ok to post the event ( I needed to post it because the window isn't open yet when the constructor fires , thus triggerevent fails ) .

Thanks In Advance
Jason

 
what if you set a flag in the constructor event and then checked the flag in the open event. If the flag is set then close the window?

Ira Rabinowitz

irarab@yahoo.com

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top