I have a JSF page which needs to display a dynamically generated image(using jfreeChart) located in the web folder. When the page is loaded it will display the previously generated image instead of the new image.The Image tag looks like as follows;
<h:graphicImage id="polarity" url="image.png" rendered="#{tweetController.renderedValue}/>
my image rendering method(This is invoked when the page load);
public void DisplayChart(Coreconf conf)
{
this.conference = conf;
GenerateImage();
renderedValue = true;
}
The controller class has a method to create an image and both are invoked when the page is loaded. The problem, the image is loaded before the execution of the create new image method. Any suggestions?
Thanks, Tharaka