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

Setting ALV grid Graphic properties from program

Hi all,

Could any one tell me how to set the properties of the histogram generated by ALV output from program.

I want to display the value on top of the bar, by setting this property from program.

Manually i can do this by selecting the graph icon from the alv toolbar, and in the graph, right-click the bar, and from the context menu, select 'format data series', then choose 'Data labels' tab and then select 'Show value'.

Thanks in advance.

regards,

Anup

Add a comment
10|10000 characters needed characters exceeded

Assigned Tags

Related questions

1 Answer

  • Posted on Nov 26, 2004 at 03:54 PM

    Hi Anup,

    the ALV uses the GFW for displaying the chart. If you need some programming examples please have a look at gfw_prog_* in se38 and see the customizing classes of the GFW in se24 (cl_cu_*).

    Regards, Kai

    Add a comment
    10|10000 characters needed characters exceeded

    • Hi Anup

      Yes, ALV Grid uses GFW for the graphics. However, it encapsulates the graphic object and let's your intervention to some extent. To do so, you can use the parameter at the interface of the method "<b>set_table_for_first_display</b>". Here is the information about the parameter:

      <u><b>IT_ALV_GRAPHICS</b></u>

      <i> Settings for displaying the ALV list as a diagram (for example, axis labels). The row type of the table has two fields (variables/value pairs):

      PROP_ID : Assign a constant attribute of the class CL_ALV_GRAPHICS_CU with prefix CO_PROPID_ to this field to determine the changes to be made to the graphic. Use the CL_ALV_GRAPHICS_CU=>CO_PROPID_TITLE attribute, for example, to refer to the title of the diagram.

      PROP_VAL : The value of the relevant topic, for example, 'My Title'.</i>

      You can also find GFW programs as "GFW_DEMO_*". If you want, you can prepare your own graphics and override the standard graphics function of the ALV Grid or add your own graphics functionality. For these you can refer to "An" target="_blank">www.sdn.sap.com/irj/servlet/prt/portal/prtroot/com.sap.km.cm.docs/documents/a1-8-4/an%20easy%20reference%20for%20alv%20grid%20control.pdf">"An Easy Reference for ALV Grid Control".

      Kind regards...

      *--Serdar

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.