﻿<?xml version='1.0' encoding='UTF-8'?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/"><channel><title>FusionCharts Forum / FusionCharts v3 / Using FusionCharts / FusionCharts and JSP  / Chart is not displaying / Latest Posts</title><generator>InstantForum.NET v4.1.4</generator><description>FusionCharts Forum</description><link>http://www.fusioncharts.com/forum/</link><webMaster>support@fusioncharts.com</webMaster><lastBuildDate>Mon, 06 Oct 2008 08:24:39 GMT</lastBuildDate><ttl>20</ttl><item><title>RE: Chart is not displaying</title><link>http://www.fusioncharts.com/forum/Topic3313-33-1.aspx</link><description>hi,&lt;/P&gt;&lt;P&gt;As i go through your code i feel to focus on some pointers below :&lt;/P&gt;&lt;P&gt;1. Please verify the path of the chart SWF files used given in createChartHTML method and in the &amp;lt;object&amp;gt; tag... though i personally feel that defining the chart again with  &amp;lt;object&amp;gt;  is unnecessary as you are already creating it using createChartHTML.&lt;/P&gt;&lt;P&gt;2. in the method createChartHTML please specify the strXML in the next parameter...i.e.&lt;/P&gt;&lt;P&gt;createChartHTML("./FusionCharts/Column2D.swf","",strXML, "Surgery",600,300,false);&lt;/P&gt;&lt;P&gt;Syntax:&lt;/P&gt;&lt;P&gt;createChartHTML(String SWFnameWithPath, String dataURLPath(URLEncoded), String dataXML, String ChartId ,int width,int height,boolean debugMode);</description><pubDate>Tue, 11 Dec 2007 00:07:33 GMT</pubDate><dc:creator>Sudipto Choudhury</dc:creator></item><item><title>Chart is not displaying</title><link>http://www.fusioncharts.com/forum/Topic3313-33-1.aspx</link><description>Hi!!!&lt;/P&gt;&lt;P&gt;         I've downloaded fusion charts software and tried to run in IE. But am not able to see the output. Am using Netbeans 5.5. I've checked everything. am able to get the data from backend to jsp but am not able to view the chart.  in the browser am getting some layout and when i click on it, it is also disappearing. here am attaching my code. can anyone give me a solution for this?&lt;/P&gt;&lt;P&gt;&amp;lt;%@ include file="./FusionCharts.jsp"%&amp;gt;&lt;BR&gt;&amp;lt;%@ page import="com.sajix.helix.actions.BaseApplicationAction, java.sql.*"%&amp;gt;&lt;/P&gt;&lt;P&gt;&amp;lt;%@ page import="java.sql.Statement"%&amp;gt;&lt;BR&gt;&amp;lt;%@ page import="java.sql.ResultSet"%&amp;gt;&lt;BR&gt;&amp;lt;%@ page import="java.sql.Date"%&amp;gt;&lt;BR&gt;&amp;lt;HTML&lt;BR&gt;   &amp;lt;HEAD&amp;gt;&lt;BR&gt;       &amp;lt;TITLE&amp;gt;FusionCharts - Database Example&amp;lt;/TITLE&amp;gt;&lt;BR&gt;       &amp;lt;SCRIPT LANGUAGE="Javascript" SRC="/FusionCharts/FusionCharts.js"&amp;gt;&amp;lt;/SCRIPT&amp;gt;&lt;BR&gt;   &amp;lt;/HEAD&amp;gt;&lt;BR&gt;   &amp;lt;BODY&amp;gt;&lt;BR&gt;   &lt;BR&gt; &lt;BR&gt;   &amp;lt;%&lt;BR&gt;       /*&lt;BR&gt;       In this example, we show how to connect FusionCharts to a database.&lt;BR&gt;       For the sake of ease, we've used a database which contains two tables, &lt;BR&gt;       which are linked to each  other. &lt;BR&gt;       */&lt;BR&gt;           &lt;BR&gt;       //Database Objects - Initialization&lt;BR&gt;       Statement st1,st2;&lt;BR&gt;       ResultSet rs1,rs2;&lt;BR&gt;       Connection con=BaseApplicationAction.dbConnection();&lt;BR&gt;       &lt;BR&gt;       String strQuery="";&lt;BR&gt;   &lt;BR&gt;       //strXML will be used to store the entire XML document generated&lt;BR&gt;       String strXML="";&lt;BR&gt;       &lt;BR&gt;       &lt;BR&gt;       //Generate the chart element&lt;BR&gt;       strXML = "&amp;lt;chart caption='Surgery report' subCaption='Yearly' width='900' height='300' id='Column3D'&amp;gt;";&lt;BR&gt;       &lt;BR&gt;       //Construct the query to retrieve data&lt;BR&gt;       strQuery = "select month(surdate),count(*) from sjx_hms_sgy where year(surdate)='2007' group by month(surdate)";&lt;BR&gt;       System.out.println(strQuery);&lt;BR&gt;       &lt;BR&gt;       st1=con.createStatement();&lt;BR&gt;       rs1=st1.executeQuery(strQuery);&lt;BR&gt;   &lt;BR&gt;       String surgeryid=null;&lt;BR&gt;       String noofsurgeries=null;&lt;BR&gt;       String totalOutput="";&lt;BR&gt;       //Iterate through each factory        &lt;BR&gt;       while(rs1.next()) {&lt;BR&gt;           System.out.println("inside while loop");&lt;BR&gt;           surgeryid=rs1.getString(1);&lt;BR&gt;           noofsurgeries=rs1.getString(2);&lt;BR&gt;           //Now create second recordset to get details for this factory&lt;BR&gt;           &lt;BR&gt;           //Generate &amp;lt;set label='..' value='..'/&amp;gt;        &lt;BR&gt;           strXML += "&amp;lt;set label='" + surgeryid + "' value='" +noofsurgeries+ "'/&amp;gt;";&lt;BR&gt;           System.out.println(strXML);&lt;BR&gt;           //Close resultset&lt;BR&gt;           &lt;BR&gt;           &lt;BR&gt;       } //end of while&lt;BR&gt;       //Finally, close &amp;lt;chart&amp;gt; element&lt;BR&gt;       strXML += "&amp;lt;/chart&amp;gt;";&lt;BR&gt;       //close the resulset,statement,connection&lt;BR&gt;       try {&lt;BR&gt;           if(null!=rs1){&lt;BR&gt;               rs1.close();&lt;BR&gt;               rs1=null;&lt;BR&gt;           }&lt;BR&gt;       }catch(java.sql.SQLException e){&lt;BR&gt;            System.out.println("Could not close the resultset");&lt;BR&gt;       }    &lt;BR&gt;       try {&lt;BR&gt;           if(null!=st1) {&lt;BR&gt;               st1.close();&lt;BR&gt;               st1=null;&lt;BR&gt;           }&lt;BR&gt;           }catch(java.sql.SQLException e){&lt;BR&gt;            System.out.println("Could not close the statement");&lt;BR&gt;           }&lt;BR&gt;       try {&lt;BR&gt;           if(null!=con) {&lt;BR&gt;               con.close();&lt;BR&gt;               con=null;&lt;BR&gt;           }&lt;BR&gt;           }catch(java.sql.SQLException e){&lt;BR&gt;            System.out.println("Could not close the connection");&lt;BR&gt;           }&lt;BR&gt;           &lt;BR&gt;       //Create the chart - Pie 3D Chart with data from strXML&lt;BR&gt;       String chartCode=createChartHTML("./FusionCharts/Column2D.swf", strXML, "" , "Surgery", 600, 300, false);&lt;BR&gt;       &lt;BR&gt;   %&amp;gt; &lt;BR&gt;   &amp;lt;%=chartCode%&amp;gt; &lt;BR&gt;   &amp;lt;object classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" codebase="&lt;A href="http://fpdownload.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=8,0,0,0"&gt;http://fpdownload.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=8,0,0,0&lt;/A&gt;" width="900" height="300" id="Column2D" &amp;gt;&lt;BR&gt;         &amp;lt;param name="movie" value="/FusionCharts/Column2D.swf" /&amp;gt;&lt;BR&gt;         &amp;lt;param name="FlashVars" value="&amp;amp;dataURL=Data.xml"&amp;gt;&lt;BR&gt;         &amp;lt;param name="quality" value="high" /&amp;gt;&lt;BR&gt;         &amp;lt;embed src="/FusionCharts/Column2D.swf" flashVars="&amp;amp;dataURL=Data.xml" quality="high" width="900" height="300" name="Column3D" type="application/x-shockwave-flash" pluginspage="&lt;A href="http://www.macromedia.com/go/getflashplayer"&gt;http://www.macromedia.com/go/getflashplayer&lt;/A&gt;" /&amp;gt;&lt;BR&gt;      &amp;lt;/object&amp;gt;&lt;BR&gt;   &amp;lt;/BODY&amp;gt;&lt;BR&gt;&amp;lt;/HTML&amp;gt;&lt;BR&gt;</description><pubDate>Mon, 10 Dec 2007 05:53:21 GMT</pubDate><dc:creator>Lettisha</dc:creator></item></channel></rss>