This week's book giveaways are in the Refactoring and Agile forums.
We're giving away four copies each of Re-engineering Legacy Software and Docker in Action and have the authors on-line!
See this thread and this one for details.
Win a copy of Re-engineering Legacy Software this week in the Refactoring forum
or Docker in Action in the Cloud/Virtualization forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

jfreechart not work when used from servlet

 
Leandro Coutinho
Ranch Hand
Posts: 423
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi!

I have a class that has a main method and when I run it, it creates the pie chart.
I have a servlet that calls the main method. It doesn't show any errors and finishes normally, but it doesn't create the pie chart.

I refreshed the project folder, the parent project folder, searched it, and nothing...

Help me!
 
Ulf Dittmer
Rancher
Pie
Posts: 42967
73
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
You seem to assume that web apps have a default directory where files you create will end up in, but they don't. You must use absolute paths in web apps.
 
Leandro Coutinho
Ranch Hand
Posts: 423
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Ulf Dittmer wrote:You seem to assume that web apps have a default directory where files you create will end up in, but they don't. You must use absolute paths in web apps.

Yes, you're right. Thank you Ulf! =)
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic