Article View: pl.comp.lang.java
Article #141704JChart i dwa wykresy z servleta
From: Piotr
Date: Wed, 15 Oct 2008 07:47
Date: Wed, 15 Oct 2008 07:47
33 lines
1792 bytes
1792 bytes
Witam
Moze ktos z Was zajmowal sie wykresami JChart i rozwiazal problem z
wieloma wykresami zwracanymi przez servlet? Servlet zawsze zwraca mi
tylko pierwszy wykres - pozostale sa ignorowane. Jak zwrocic kolejne
wykresy aby byly widoczne w przegladarce?
Oto metoda service() servleta, z ktorej uzyskuje tylko jeden wykres:
public void service( HttpServletRequest req, HttpServletResponse
response ) throws ServletException, IOException {
try
{
PieChart2D pieChart2D = new PieChart2D(this.getData(),
this.legendProperties, this.chartProperties, this.width, this.height );
ServletEncoderHelper.encodeJPEG131(pieChart2D, 1.0f, response);
// tak nie mozna uzyskac drugiego wykresu
PieChart2D pieChart2D_2 = new PieChart2D( this.getData(),
this.legendProperties, this.chartProperties, this.width, this.height );
ServletEncoderHelper.encodeJPEG131(pieChart2D_2, 1.0f, response);
}
catch( Throwable throwable )
{
//HACK do your error handling here...
throwable.printStackTrace();
}
}
Bede wdzieczny za informacje
pozdrawiam
Piotr
Technical Details
Message-ID:
<gd47a8$bun$1@inews.gazeta.pl>Path:
mbox-mo1.pugleaf.net!news-archive.icm.edu.pl!news.gazeta.pl!not-for-mailShow Full Headers
Complete Article Headers
Path: mbox-mo1.pugleaf.net!news-archive.icm.edu.pl!news.gazeta.pl!not-for-mail From: Piotr <p_1974@tlen.pl> Newsgroups: pl.comp.lang.java Subject: JChart i dwa wykresy z servleta Date: Wed, 15 Oct 2008 09:47:30 +0200 Organization: "Portal Gazeta.pl -> http://www.gazeta.pl" Lines: 33 Message-ID: <gd47a8$bun$1@inews.gazeta.pl> NNTP-Posting-Host: 62.29.174.65 Mime-Version: 1.0 X-Trace: inews.gazeta.pl 1224056968 12247 62.29.174.65 (15 Oct 2008 07:49:28 GMT) X-Complaints-To: usenet@agora.pl NNTP-Posting-Date: Wed, 15 Oct 2008 07:49:28 +0000 (UTC) X-User: mazipalm User-Agent: Thunderbird 2.0.0.16 (X11/20080723) Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit