Browser close event handling and dispatch

36 views
Skip to first unread message

matiasx

unread,
Aug 21, 2012, 12:49:54 PM8/21/12
to flex_...@googlegroups.com
Hi all,

I'm facing a problem when closing my browser.
I'd like to know if it's possible to dispatch a call to my service for make a logout call.
I try ExternalInterface.addCallback and define my function on JavaScript but i can`t get to my backend that is on Java.

I don't know if is a matter of timming. I mean, my browser close so fast that i can't even get throuht my Java services.

Any clue will be nice.
PS: I'm using Swiz framework
Regard

Motish Jain

unread,
Jun 27, 2013, 10:38:27 AM6/27/13
to flex_...@googlegroups.com
Even I am facing this issue. I thought of an approach of setTimout but this wont be a good approach to solve this problem.

Please tell me when you get a solution

Manikandan S

unread,
Jun 27, 2013, 10:41:18 PM6/27/13
to flex_...@googlegroups.com
Hi,

You can invoke your service from java script on browser onunload event. This event will get fired while closing browser window.

Just try it out.



--
You received this message because you are subscribed to the Google Groups "Flex India Community" group.
To unsubscribe from this group and stop receiving emails from it, send an email to flex_india+...@googlegroups.com.

To post to this group, send email to flex_...@googlegroups.com.
Visit this group at http://groups.google.com/group/flex_india.
For more options, visit https://groups.google.com/groups/opt_out.
 
 



--

Regards,                
Manikandan.S 
Reply all
Reply to author
Forward
0 new messages