How can we create dynamic pie chart in jsp

hi im a new jsp programmer and i just want to know how can i create dynamic pie chart in jsp

http://sourceforge.net/projects/jfreechart
- Saish

Similar Messages

  • How can I create a Pie charts ?

    HI all,
    I'm a beginner in java and i'm investigate in a web project (website) which should display statistical charts. I did a beans to generate basic bar charts, but it is most difficult to build a Pie chart. That's why i need help to put me on the rigth way to build Pie Charts beans (this pie charts should be filled up with db query).
    Every kind of help will be appreciated.
    Thanks in advance
    Hope someone can help me.
    STF

    I take it you constructed the bar graphs using html and images together?
    Obviously it's a little more difficult to make a pie chart with html. Chances are that it will have to be an image rendered by a Servlet or JSP. I suggest looking at how to create images using AWT or swing. This will allow you to create a circle with different color slices and what not. Then you need a Servlet or JSP that will send the image out the output stream. You can then place an image tag in your html page like this <img src="http://myserver.com/PieChartServlet>
    I'm actually working on an API myself that will render pretty histograms (line graphs), and hopefully pie charts down the road. It's going to be an open source project. I decided to make my own API when I looked at some others out there who were charging an arm and a leg for theirs. Chart Builder for example, it's like $6K for their java based API <choke>.
    So if you're interested, or anyone else is, shoot me an email and I'll let you know when the beta is ready. [email protected]
    -Derek

  • How can i create a pie chart

    Hi all,
    I'm a beginner in java and i'm investigate in a web project (website) which should display statistical charts. I did a beans to generate basic bar charts, but it's most difficult to build a pie chart. That's why i need help to put me on the right way of building a Piechart beans.
    All kind of help will be precious
    Thanks in advance.
    STF

    Thanks a lot for your reply.
    But it shall works in a beans and this was set up only for applications or applet. Besides it seems (i'm really not sure but i have found lot of thread)that an applet can't be run into a jsp page that is searching data into db (thanks to sql query)
    : there is a problem of buffer (tomcat can't generate the jsp page in the same time as it execute the applet).
    Let me know if i'm wrong or not please ?
    Regards
    STF

  • Can't create dynamic html elements with jsp????? important

    Hi All,
    I am having problem creating dynamic html elements with jsp tags, i have tried to use EL and java scriplet, both of them don't work.
    i am trying to create dynamic menu in my "rightMenu.jspf", based on, if user has logged in or not.
    some like this!
    <jsp:if test ="${validUser == null}">
    some simple text menu here
    </jsp:if>
    but it is not working. it simply loading all and images with in statement, regardless of whether user has logged in or not. i think some how if statement is not working properly.
    "validUser" is a session bean, which is not creating at this point, it will created when user will log in successfully. and also this session bean does not exist at the page, where i am trying to check that .
    Is there any way to create dynamic values in jsp. It is really important, is there any body who help me in this matter. i would be really grateful.
    zaman

    hi jaspre,
    thanks for replying me. you know what, is it not something wrong with web.xml file. i remember once, i deleted some from there, a property with "*.jsp". i can't remember what exactly was it though.
    all if statements works on files ending with extension ".jsp" but don't work only on with extension ".jspf". there must be to do with this.
    <?xml version="1.0" encoding="UTF-8"?>
    <web-app version="2.4" xmlns="http://java.sun.com/xml/ns/j2ee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd">
    <servlet>
    <servlet-name>ValidateServlet</servlet-name>
    <servlet-class>ValidateServlet</servlet-class>
    </servlet>
    <servlet-mapping>
    <servlet-name>ValidateServlet</servlet-name>
    <url-pattern>/ValidateServlet</url-pattern>
    </servlet-mapping>
    <servlet>
    <servlet-name>dwr-invoker</servlet-name>
    <servlet-class>org.directwebremoting.servlet.DwrServlet</servlet-class>
    <init-param>
    <param-name>debug</param-name>
    <param-value>true</param-value>
    </init-param>
    <init-param>
    <param-name>pollAndCometEnabled</param-name>
    <param-value>true</param-value>
    </init-param>
    </servlet>
    <servlet-mapping>
    <servlet-name>dwr-invoker</servlet-name>
    <url-pattern>/dwr/*</url-pattern>
    </servlet-mapping>
    <session-config>
    <session-timeout>
    30
    </session-timeout>
    </session-config>
    <welcome-file-list>
         <welcome-file>
    main.jsp
    </welcome-file>
    </welcome-file-list>
    </web-app>
    if any one can figure it out. i would be grateful.
    zaman

  • How to create a pie chart with jsp/servlet?

    I want to create a servlet which can be used like below:
    <img src="pieservlet?param1=<%=x%>&param2=<%=y%>&..." width="100" height="100" >
    can you give me some guide?

    Hai ,
    I have implemented a trial working pie chart , dynamically created from jsp using ServletOutputStream , BufferedImage & JPEGImageEncoder (found in com.sun.image.codec.jpeg.* package & bundled along with jdk ) .
    <%
    ServletOutputStream sout = response.getOutputStream();
    response.setContentType("image/jpeg");
    BufferedImage img = new BufferedImage(400,400,BufferedImage.TYPE_INT_RGB);
    Graphics2D gr = img.createGraphics();
    /* Actually this will be got as values of request.getParameter */
    Vector values = new Vector();
    values.addElement(new String("45") );
    values.addElement(new String("125") );
    values.addElement(new String("75") );
    values.addElement(new String("25") );
    values.addElement(new String("90") );
    // my demo class      
    temp.pieChart fr = new temp.pieChart(400,400,values);
    /* This pieChart is class extends JFrame , in paint method of it all Drawing of pie chart using graphics2D fillArc done */
    fr.paint(gr);
    JPEGImageEncoder encoder = JPEGCodec.createJPEGEncoder(sout);
    encoder.encode(img);
    sout.flush();
    %>
    Hope this helps to build your own custom pie chart .
    Let me know if details needed on pieChart class
    rakesh
         

  • How can i Create Dynamic mailing lists with Iplanet Delegated Administrator

    Hello people,
    Could anyone help me in this matter please?
    I am running IMS5.2 with Netscape Directory4.16. I need help about how to create a Dynamic Mailing list using de Iplanet Delegated Administrator, not using the traditional Netscape Console.
    If someone can help me, i will apreciate.
    bye.
    Azim Lakha

    In 24.4.0 there is no File|New|Address Book. There is File|New|Address Book Contact. How do I create a new address book ?

  • How can we create dynamic query

    can any one please tell me how can we cretae a dynamic query in android by join two tables

    Hi Mousumi,
    Can you please be more brief on the question.
    cretae a dynamic query in android by join two tables
    What do you mean by this ?

  • How can I create dynamic file references in Power Query?

    Hi all,
    I'm new at using PowerQuery, and so far I like it. There's one thing I am struggling with though... Once I have set up my PoweQuery connections, I don't find an easy way to change the file to which the query is connecting. I'm using it for a monthyl recurring
    process, and every month the source data to query on woudl be different. The same in format/structure, but just a different dataset.
    Is there a way to make the source setup more dynamic? Can I for example in a parameters sheet enter the name and path of the new source file and update the queries?
    Currently the Advanced editor shows me following file reference:
    let
        Source = Excel.Workbook(File.Contents("Z:\Templates\EMEA\Source Data Tables\EMEA_EW_Source_Data_for_Power_Queries v1.xlsm")),
    Thanks in advance for suggestions

    Yes, this is something that you can do with Power Query. Here's how you can do it:
    Create a table in Excel containing your parameter value. Let's say that it has one column, called ParameterValue, and one row.
    Create a new Power Query query that gets the data from this table. Call the query something like ParameterQuery.
    In your original query you will now be able to reference values from your parameter query by saying something like this:
    Source = Excel.Workbook(File.Contents(ParameterQuery[ParameterValue]{0})),
    HTH,
    Chris
    Check out my MS BI blog I also do
    SSAS, PowerPivot, MDX and DAX consultancy
    and run public SQL Server and BI training courses in the UK

  • How can I create a Login-page with jsp???

    Hello,
    I have to create a page with JSP code on the Netweaver Developer Studio.
    But I do not know how I do it.
    Can anyone tell me what to write in the portalapp.xml?
    An example would be very helpful.
    Thank you
    Greetings

    As you can see in the example:
    The portalapp.xml file (deployment descriptor) provides configuration information for your application, and defines the components and services in your application. For each component and service, you specify the implementing Java class and configuration information.
    For more information on the format of the portalapp.xml, see Deployment Descriptor (portalapp.xml).
    <application>
        <application-config>
            <property name="SharingReference" value="com.sap.portal.navigation.service, com.sap.portal.navigation.api_mimeservice, com.sap.portal.navigation.helperservice"/>
            <property name="Vendor" value="MY_COMPANY"/>
            <property name="SecurityArea" value="PERMISSION"/>
        </application-config>
        <components>
            <component name="SimpleNavigationExample">
                <component-config>
                    <property name="ClassName" value="MY_CLASS"/>
                    <property name="SecurityZone" value="no_safety"/>
                </component-config>
                <component-profile/>
            </component>
        </components>
        <services/>
    </application>
    You can only update in this example, your class name and other details:
    <property name="Vendor" value="sap.com"/>
    <property name="SecurityArea" value="MyCompany"/>
    <property name="ClassName" value="LOGINCLASS"/>
    <property name="SecurityZone" value="no_safety"/>
    Modify this portalapp.xml file as follows:
           1.      NAVIGATION SERVICE, so you must add references to the following portal applications that define these services:
            com.sap.portal.navigation.service
            com.sap.portal.navigation.api_mimeservice
            com.sap.portal.navigation.helperservice
           2.      In the <application-config> section, create the following properties that help to define the security zone for all components and services in this application:
    ○     Vendor: String identifying the company or organization that provided the application, for example, sap.com.
    ○     SecurityArea: String identifying the security area for the application, for example, NetWeaver.portal.
           3.      In the <component-config> section for the mySiteMap component, create the property SecurityZone to define the specific security zone for the component.
    For Permission, check this document:
    http://help.sap.com/saphelp_nw04s/helpdata/en/44/489e2df5ee4e35e10000000a1553f6/frameset.htm

  • How to Create a PIE chart with PPR

    Hi All,
    Can you please help me to achieve the below.
    Can we create any Pie Chart. In Pie chart If we have 5 Parts when I click on any part of Pie chart It should display my new region below to the chart in the same page Page)?
    Regards,
    Mahendra.

    Hi
    For Creation of pie- chart Please refer to dev guide under the section pie-graph
    and as per ur req use the normal ppr for diff sections of pie-graph
    regards
    SasiKasyap .

  • Buisness graphics dynamic PIE chart event id

    HI all,
    I'm trying to create dynamic PIE chart :
    Link to sdn document *
    First I declared in the context node a table ( 0…n )
    PIE – 0…N  with attributes :
    Categorty – type string
    Series – type i
    Then I'm creating the business graphics :
    DATA:lr_graph TYPE REF TO cl_wd_business_graphics,
    lr_cat TYPE REF TO cl_wd_category,
    lr_series TYPE REF TO cl_wd_simple_series,
    lr_container TYPE REF TO cl_wd_uielement_container,
    lr_flow TYPE REF TO cl_wd_flow_data.
    lr_container ?= view->get_element( 'ROOTUIELEMENTCONTAINER' ).
    lr_graph = cl_wd_business_graphics=>new_business_graphics(
    bind_series_source = 'NODE_DYN'
    chart_type = cl_wd_business_graphics=>e_chart_type-pie
    height = 340
    width = 750
    id = 'GRAPH' ).
    lr_flow = cl_wd_flow_data=>new_flow_data( element = lr_graph ).
    lr_container->add_child( lr_graph ) .
    wd_this->value_cs ?= lr_graph.
    wd_this->mr_view ?= view.
    Now I'm creating the category and series :
    wd_this->value_cs =? Lr_graph
    wd_this->mr_view ?= view.
    Series :
    DATA: lr_bgr_ss TYPE REF TO cl_wd_simple_series.
    lr_bgr_ss = cl_wd_simple_series=>new_simple_series(
    bind_value = ‘NODE_DYN.SERIES’
    label = ‘Series_1’
    event_id = ‘Series_1’
    id       = ‘Series_1’
    view = wd_this->mr_view ).
    Wd_this->value_cs->add_series( lr_bgr_ss ).
    Category :
    DATA: lr_bgr_cs TYPE REF TO cl_wd_category.
    lr_bgr_cs = cl_wd_category=>new_category(
    view = wd_this->mr_view
    event_id = ‘Series_1’
    id       = ‘Series_1’
    bind_description = 'NODE_DYN.CATEGORY').
    wd_this->value_cs->set_category( lr_bgr_cs ).
    Now I'm binding the data :
    Data : ls_pie type wd_this->element_pie.
    Data : lt_pie type table of element_pie.
    ls_pie-category = 'test_category1'.
    ls_pie-series = '34'.
    Append ls_pie to lt_pie.
    ls_pie-category = 'test_category2'.
    ls_pie-series = '73'.
    Append ls_pie to lt_pie.
    Data : lo_nd_pie type ref to if_Wd_context_node.
    Data : lo_el_pie type ref to if_wd_context_element.
    Lo_nd_pie = wd_context->get_child_node(
    Name = wd_this-> wdctx_pie.
    The above is the only way that I succeeded to create 2 categories for the pie chart but I cant isolate the event id for every category.
    I tried also to create another series with the same id and other event id but still got the same problem.
    Please suggest a solution for creating dynamic pie chart with event id for every category or series .
    Regards,
    Arie.

    Hi Rama,
    Thank you for your reply ,
    I added the BIND_EVEND_ID = 'NODE_DYN.SERIES'  and it worked fine.
    I'm trying now to get rid of the static context element.
    I've declared the following :
    DATA : NODE_INFO TYPE REF TO IF_WD_CONTEXT_NODE_INFO ,
                  STRUCT_TYPE TYPE REF TO CL_ABAP_STRUCDESCR ,
                  TABLE_TYPE REF TO CL_ABAPDESCR=>COMPONENT_TABLE,
                 COMP LIKE LINE OF COMP_TAB.
    COMP-NAME = 'CATEGORY'.
    COMP_TYPE ?= CL_ABAP_DATADESCR=>DESCRIBE_BY_NAME( 'STRING' ).
    APPEND COMP TO COMP_TAB.
    COMP-NAME = 'SERIES'.
    COMP_TYPE ?= CL_ABAP_DATADESCR=>DESCRIBE_BY_NAME( 'I' ).
    APPEND COMP TO COMP_TAB.
    STRUCT_TYPE = CL_ABAP_STRUCTDESCR=>CREATE( COMP_TAB ).
    NODE_INFO = WD_CONTEXT->GET_NODE_INFO( ).
    NODE_INFO = NODE_INFO->ADD_NEW_CHILD_NODE (
    NAME = 'NODE_DYN'
    IS_MANDTORY = ABAP_FALSE
    IS_MULTIPLE = ABAP_TRUE
    STATIC_ELEMENT_RTTI = STRUCT_TYPE
    IS_STATIC = ABAP_FALSE) .
    FIELD-SYMBOLS  <TABLE> TYPE TABLE.
    FIELD-SYMBOLS  <WA> TYPE WA.
    DATA : TABLE TYPE REF TO DATA.
    DATA : WA TYPE REF TO DATA.
    CREATE DATA TABLE LIKE TABLE OF STRUCT_TYPE.
    ASSIGN TABLE->* TO TABLE.
    TODO ?? - Add data to FS <TABLE>
    *Binding :
    DATA : DYN_NODE TYPE REF TO IF_WD_CONTEXT_NODE.
    DYN_NODE = WD_CONTEXT->GET_CHILD_NODE( NAME = 'NODE_DYN').
    DYN_NODE->BIND_TABLE( <TABLE> ).
    How do I append data to FS <table> with the relevant components ?
    Is there any  other efficient way to append the data and bind  ?
    Regards,
    Arie.

  • Pie Chart in JSP

    Hi
    I want to create a Pie Chart in JSP. The data will come from Oracle Database. I am not very good with managing big open source projects like Cewolf to draw charts. Is it possible to do this in the simplest way possible as I am not experienced in this technology.
    Please send me the link to the simplest way to do it or guide me.
    Thanks in advance.

    Thanks alot. The example shown works fine on my local
    machine where I have got TomCat but it does not work
    on my university server as they say they do not have
    graphics card on their server and therefore any
    java.awt or swing class can not be used on server sideSo I guess you have to use another server's capability, like the one in play-free-games.com, for example :
    http://www.play-free-games.com/webmasters/dynamic-piechart/dynamic-piechart.cfm

  • How can i create a button with a dynamic picture?

    How can i create a button with a dynamic picture using
    mcLoader.loadClip
    I did create one with it doesnt seem to be working. It loses
    all its
    functions (eg onPress onRelease)
    Thanks

    I solved thep roblem anyway creating a mc.. then creating
    another MC withing
    the first MC and i change the picture on the second MC. And i
    apply the
    propierities to the first MC , and works
    If i have troubles with mu sistem on the future I will use
    yours!
    Thanks!
    "the fleece" <[email protected]>
    escribi� en el mensaje
    news:e67i88$jlf$[email protected]..
    > the image loading will remove any properties or
    functions the mc had.
    >
    > you need to apply them in the onLoadInit function
    >
    > mclListener.onLoadInit = function(target_mc:MovieClip) {
    > target_mc.onRollOver=blah blah
    > };
    > var image_mcl:MovieClipLoader = new MovieClipLoader();
    > image_mcl.addListener(mclListener);
    > image_mcl.loadClip(blah, blahblah);
    >
    >

  • How to create a pie chart from a pop-up menu in Numbers?

    I would like to be able to select a persons name from the Pop-up menu in the E column to chose who has bought an item. I would then like to create a pie chart showing how much money each person has spent on buying the items and have this update automatically. I have no idea how I would go about doing this. Any help would be greatly appreciated.
    Thanks

    Costs per person, with "Ali & Baker" as a separate entity (since no provision for separating costs)
    The formula is this:
    =SUMIFS($Cost, $Who Bought it?, "="&$Who Bought it?, $Bought?, "=TRUE")
    The reasoning is:
    Sum all Costs, if the following conditions are true:
    $Who Bought it?, "="&$Who Bought it?
    Group items in the 'Who Bought it? column that match the item in the same row as the formula.
    $Bought?, "=TRUE"
    Only include items that have actually been bought.
    Screenshot
    I have highlighted the selected cell in red. 
    The coloured columns show which ones are relevant to the formula.
    To create the totals, I added Footer rows to the table.
    You could make a separate table if you prefer.
    To create the pie chart, I selected just the costs in the footer rows, and clicked on Charts.

  • Dynamic Pie Chart in Smart Form

    Hi Frn's ,
      How can i show the dynamic Pie chart in Smartform .
    Thanks and Regards
    Priyank Dixit

    Hi,
    Refer to this link [How to display pie chart in smart forms|Re: how to display pie chart in smart forms]

Maybe you are looking for

  • Tables in which LSMW data is stored?

    Hi Gurus, I would like to know the base tables that LSMW uses. My actual requirement is to fetch the action log of the LSMW object. No option is provided in R/3 to download Action Log of an LSMW object into Excel. Hence I am trying to find the tables

  • How can i delete duplicates photos in iPhoto without doing it one by one? Thx

    how can i delete duplicates photos in iPhoto without doing it one by one? Thx

  • DBAdapter procedure call issue (dev and test env have seperate schema)

    Hi All We are facing an issue with DBAdapter (even after commenting the schema name from JCA file). The procedure is using SQL objects and collections. The DBAdapter is trying to find these objects in the old schema (the one used in dev) but they are

  • Closing out Web pages

    I am having a problem closing out games on some game sites. It has been mentioned that I have a javascript error. Games load ok but when try to vclose to go to another game the page will not close out. Can anyone help?

  • Sharpening Still images

    I've heard that still images should not be sharpened before importing to FC as they tend to pixelate and will 'shake" during TV playback. Question: If I start with RAW file, bring in as a Tiff, should I sharpen just a little (e.g. a minimal amount in