Language: ChineseGermanSpanishFrenchDutchItalianRussian
123 Flash Chat Forums

Go Back   TOPCMM Community > SWFKit > SWFKit Support

Reply
 
LinkBack Thread Tools Display Modes
  #1 (permalink)  
Old 08-01-2006, 09:35 AM
Junior Member
 
Join Date: Jun 2005
Posts: 22
Default Close window event

Hi everybody ..

Please tell me how can I knew if the user closes a specified window or not without using RunAndWait method , because when I used this method my application was not responding .

I used the following code but it doesn't return any value when the window closed :

Code:
App = Shell.run("Program.exe");
W = new Window(App.handle); 
W.onClose = function (){
Dialogs.msgBox("window closed");
}
App.close();
Reply With Quote
  #2 (permalink)  
Old 08-07-2006, 01:37 PM
Senior Member
 
Join Date: Dec 2002
Posts: 2,015
Default Re:Close window event

You cannot handle the onClose event of another application, because it does not run in the same process of your main app.

And the way to handle event in action script is different from that in ffish script. For example, to handle the onClose event of the main window, you would have to do like this:
Code:
import SWFKit.*;
function onClose()
{
    Dialogs.msgBox("about to close!");
}

var wnd = Global.getMainWnd();
wnd.setEventHandler("onClose", onClose);
Reply With Quote
  #3 (permalink)  
Old 08-07-2006, 03:59 PM
Junior Member
 
Join Date: Jun 2005
Posts: 22
Default Re:Close window event

Okay .. Thank you for your reply .
Reply With Quote
Reply

Was this information helpful?    Yes No



Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On



All times are GMT. The time now is 03:49 AM.


Powered by vBulletin® Version 3.7.1
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 3.1.0 ©2007, Crawlability, Inc.