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

Printing format control in ALV TREE

Hello there,

I searched all over SDN but I couldn't find a solution for my problem ! It would be nice of you if you can help me sort it out.

I'm using an ALV TREE :

DATA: gv_tree TYPE REF TO cl_gui_alv_tree

CALL METHOD gv_tree->set_table_for_first_display

EXPORTING

is_hierarchy_header = gv_hierarchy_header

it_list_commentary = gv_report_title

i_save = 'A'

is_variant = gv_variant

CHANGING

it_outtab = gt_output_empty "Must be empty

it_fieldcatalog = gt_fieldcat.

I need to change printing format from X_65_255 to X_44_120.

In this method, there is no IS_PRINT to insert the new format (it exists only for GRID).

Do you have any idea?

Add a comment
10|10000 characters needed characters exceeded

Assigned Tags

Related questions

6 Answers

  • author's profile photo Former Member
    Former Member
    Posted on Sep 09, 2010 at 12:27 PM

    Hi,

    You can do it changing the value of the var system SY-PAART, hope it helps you.

    Regards,

    Felipe Simionatto

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Sep 09, 2010 at 12:40 PM

    Thanks for your answer Felipe!

    But it doesn't work...

    Any other ideas? Anyone?

    Tarick.

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Sep 09, 2010 at 02:10 PM

    I could not find a way to do it in CL_GUI_ALV_TREE but you can use CL_GUI_ALV_GRID and the same method SET_TABLE_FOR_FIRST_DISPLAY in this class you can pass the print parameters to IS_PRINT (the component is PRINT_CTRL).

    Revert back if it works.

    Regards,

    Felipe Simionatto

    Edited by: fsimionatto on Sep 9, 2010 4:13 PM

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Sep 09, 2010 at 02:27 PM

    Hi Felipe!

    I know it works perfectly for CL_GUI_ALV_GRID but in my case I'm printing an ALV TREE so I can only use CL_GUI_ALV_TREE. Do I have any other choice?

    Thanks again!

    Tarick.

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Sep 09, 2010 at 02:48 PM

    Hi Simone!

    I tried but it doesn't work. The format is still X_65_255. Is there any way to change this default setting?

    Thanks!

    Tarick.

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Sep 09, 2010 at 03:12 PM

    Hi again!

    In fact, the print output with format X_65_255 is very small that's why I need it in X_44_120. The dynpro is not a problem.

    Thanks!

    Tarick.

    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.