Skip to Content
author's profile photo Former Member
Former Member

Printing a Line Graph in SAP

Hi Experts,

Can anybody tell me how to print line graph in SAP. I do not want use ALV print function for graph generation.

Here I am attaching you sample program for your reference. Name of the program is GFW_PROG_PRES_SHOW_MULT.

Thanks in Advance.

Regards,

Shaik.

Add a comment
10|10000 characters needed characters exceeded

Assigned Tags

Related questions

2 Answers

  • author's profile photo Former Member
    Former Member
    Posted on Oct 12, 2010 at 05:43 PM

    you'll notice that some of the charts in transaction GRAL have right-click print capability. You'll need to find the demo program for those and adapt that code.

    Add a comment
    10|10000 characters needed characters exceeded

  • Posted on Oct 12, 2010 at 06:07 PM

    Hi Meera,

    you can use FM "GRAPH_MATRIX_3D' to print graphs. See if this works out good for your.

    Simple code to use this would be as follows.

    DATA: BEGIN OF itab_data OCCURS 0,

    dataname(15),

    quantity1 TYPE i,

    quantity2 TYPE i,

    quantity3 TYPE i,

    END OF itab_data,

    BEGIN OF itab_options OCCURS 0,

    option(20),

    END OF itab_options.

    itab_data-dataname = 'Electricity'.

    itab_data-quantity1 = 55.

    itab_data-quantity2 = 62.

    itab_data-quantity3 = 59.

    APPEND itab_data.

    itab_data-dataname = 'Gas'.

    itab_data-quantity1 = 35.

    itab_data-quantity2 = 52.

    itab_data-quantity3 = 44.

    APPEND itab_data.

    itab_data-dataname = 'Water'.

    itab_data-quantity1 = 18.

    itab_data-quantity2 = 22.

    itab_data-quantity3 = 19.

    APPEND itab_data.

    CALL FUNCTION 'GRAPH_MATRIX_3D'

    EXPORTING

    col1 = 'Jan'

    col2 = 'Feb'

    col3 = 'Mar'

    titl = 'Gráfico Teste - Carlos'

    TABLES

    data = itab_data

    opts = itab_options

    EXCEPTIONS

    OTHERS = 1.

    Hope this helps.

    Thanks

    Sumit

    Add a comment
    10|10000 characters needed characters exceeded

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.