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

set_print_parameters

expert!

im having a problem with the alignment of my page.i used set_print parameters.im printing a paper in landscape type and i used 'X_65_255' as its layout and 63 as its line count and 255 as its line size.problem is when i print the second page it starts on the fourth line instead of starting in the first line of the page.

can you share your ideas with me guys on how i would fix this problem?my first page is ok but the preceding pages were not.

Add a comment
10|10000 characters needed characters exceeded

Assigned Tags

Related questions

1 Answer

  • author's profile photo Former Member
    Former Member
    Posted on Mar 07, 2008 at 04:56 AM

    Hi,

    Chk out this program,

    REPORT SAPMZTST NO STANDARD PAGE HEADING LINE-COUNT 0(2).

    PARAMETERS P TYPE I.

    INITIALIZATION.

    CALL FUNCTION 'SET_PRINT_PARAMETERS'

    EXPORTING

    ARCHIVE_MODE = '3'

    COPIES = '5'

    DEPARTMENT = 'BASIS'

    DESTINATION = 'LT50'

    EXPIRATION = ' '

    IMMEDIATELY = 'X'

    LAYOUT = 'X_65_132'

    LINE_COUNT = 54

    LINE_SIZE = 20

    LIST_NAME = 'Test'

    LIST_TEXT = 'Test for User''s Guide'

    NEW_LIST_ID = 'X'

    RECEIVER = 'KELLERH'

    RELEASE = ' '

    SAP_COVER_PAGE = 'X'

    START-OF-SELECTION.

    DO P TIMES.

    WRITE / SY-INDEX.

    ENDDO.

    TOP-OF-PAGE.

    WRITE: 'Page', SY-PAGNO.

    ULINE.

    END-OF-PAGE.

    ULINE.

    WRITE: 'End of', SY-PAGNO.

    After executing this program, the user can enter a value for parameter P on the selection screen (for example 100) and choose Execute + print. The system then displays this dialog window:

    Chk out this links..

    http://help.sap.com/saphelp_40b/helpdata/en/9f/dba58735c111d1829f0000e829fbfe/content.htm

    Hope this helps u,

    Regards,

    Arunsri

    Add a comment
    10|10000 characters needed characters exceeded

    • Because Function Type is Conflicted.

      Plz use this source.

      After executing this program, press the key Ctrl + P .

      you can see the values are same the parameters in fuction module 'SET_PRINT_PARAMETERS'.

      REPORT  z_test001 NO STANDARD PAGE HEADING LINE-COUNT 0(2).
      
      
      DATA :archive_mode  LIKE  pri_params-armod VALUE '3',
            copies  LIKE  pri_params-prcop VALUE '5',
            department  LIKE  pri_params-prabt VALUE 'BASIS',
            destination LIKE  pri_params-pdest VALUE 'LT50',
            expiration  LIKE  pri_params-pexpi VALUE ' ',
            immediately LIKE  pri_params-primm VALUE 'X',
            layout  LIKE  pri_params-paart VALUE 'X_65_132',
            line_count  LIKE  pri_params-linct VALUE '54',
            line_size LIKE  pri_params-linsz VALUE '20',
            list_name LIKE  pri_params-plist VALUE 'TEST',
            list_text LIKE  pri_params-prtxt VALUE `Test for User's Guide`,
            new_list_id LIKE  pri_params-prnew VALUE 'X',
            receiver  LIKE  pri_params-prrec VALUE 'KELLERH',
            release LIKE  pri_params-prrel VALUE ' ',
            sap_cover_page  LIKE  pri_params-prsap VALUE 'X'.
      
      PARAMETERS p TYPE i DEFAULT 10.
      
      INITIALIZATION.
      
        CALL FUNCTION 'SET_PRINT_PARAMETERS'
          EXPORTING
            archive_mode   = archive_mode
            copies         = copies
            department     = department
            destination    = destination
            expiration     = expiration
            immediately    = immediately
            layout         = layout
            line_count     = line_count
            line_size      = line_size
            list_name      = list_name
            list_text      = list_text
            new_list_id    = new_list_id
            receiver       = receiver
            release        = release
            sap_cover_page = sap_cover_page.
      
      START-OF-SELECTION.
      
        DO p TIMES.
          WRITE / sy-index.
        ENDDO.
      
      TOP-OF-PAGE.
      
        WRITE: 'Page', sy-pagno.
        ULINE.
      
      END-OF-PAGE.
        ULINE.
        WRITE: 'End of', sy-pagno.

      Edited by: Jaime White 999 on Aug 22, 2011 4:08 AM

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.