Jfree Chart Frame Close Button

A discussion forum for JFreeChart (a 2D chart library for the Java platform).
Locked
sumaya.baig
Posts: 12
Joined: Tue Nov 07, 2006 6:53 am
Contact:

Jfree Chart Frame Close Button

Post by sumaya.baig » Tue Nov 07, 2006 6:59 am

Hi, i am developing a jsp using struts framework. After submitting the form and going to the action class, i instantiate the jfree chart class that i have created. Now, the chart pops up in a new frame which is great but as soon as the user closes this frame using the cross on the right hand corner of the title bar, the server shuts down ! Can someone please tell me why this is happening and how I can prevent this from happening ?

david.gilbert
JFreeChart Project Leader
Posts: 11734
Joined: Fri Mar 14, 2003 10:29 am
antibot: No, of course not.
Contact:

Post by david.gilbert » Tue Nov 07, 2006 10:55 am

I can't help you with that, sorry. I don't do much work with web apps (lucky me!).
David Gilbert
JFreeChart Project Leader

:idea: Read my blog
:idea: Support JFree via the Github sponsorship program

sumaya.baig
Posts: 12
Joined: Tue Nov 07, 2006 6:53 am
Contact:

Post by sumaya.baig » Tue Nov 07, 2006 11:00 am

ahhh ... ok i'll wait for some1 else ! :)

Taqua
JFreeReport Project Leader
Posts: 698
Joined: Fri Mar 14, 2003 3:34 pm
Contact:

Post by Taqua » Tue Nov 07, 2006 11:38 am

Your WebApplication opens a local Swing-Frame?

I guess your Servlet-Container runs on the same machine as your browser. Imagine the fun your remote users (those without physical access to the server) have, once they realize that their action opened up a Frame on a server that is maybe a few hundred miles away. How should *they* close the frame?

(And you're using the 'ApplicationFrame' directly from the ChartDemos. Nice, but that one calls System.exit() (as it is there for DEMO purposes, not for the real world application). Your funny programming killed the server :)

It would be cool, if you buy a book about the basics on how the web works, and after reading it, reconsider your application's design ;)

Regards,
Thomas

sumaya.baig
Posts: 12
Joined: Tue Nov 07, 2006 6:53 am
Contact:

Post by sumaya.baig » Tue Nov 07, 2006 11:58 am

hmm ... i guess i am re-cooking the demo programs which use ApplcationFrame directly !!

sumaya.baig
Posts: 12
Joined: Tue Nov 07, 2006 6:53 am
Contact:

Post by sumaya.baig » Tue Nov 07, 2006 1:58 pm

Thanks for the help thomas ! ... i've fixed de problem ! :D

Locked