Calculation in SAPscript

Hello ppl,
Currently the MAIN window of my SAPscript is coded as below:
/:   IF condition = 'L'
/*   Qty = &RESBD-MENGE(C)&
/:   ENDIF
now i want to print it as
Qty = &RESBD-MENGE& minus &RESBD-DENMNG&.
Both the values are present in the sapscript at runtime.
How do i calculate this in sapscript and print the result?
Pls help.

Hi Padmavathi,
For the test purpose, i have written as below:
in sapscript:
/:   DEFINE &TOTAL&
/:   PERFORM GET_TOTAL IN PROGRAM Z101812_SCRIPT
/:   USING &WA_EKPO-NETPR&
/:   CHANGING &TOTAL&
   Total = &TOTAL&.
in report:
FORM get_total TABLES in_tab STRUCTURE itcsy
                      out_tab STRUCTURE itcsy.
data: price type vbap-netwr,
        total type vbap-netwr.
read table in_tab index 1.
price = in_tab-value.
total = price + 10.
read table out_tab index 1.
move total to out_tab-value.
modify out_tab.
ENDFORM.                    "get_total
But, the total is not being printed.
Can you pls help me find out the reason?
Thanks.

Similar Messages

  • Exhange rate calculations in SAPScript

    Hi,
    I am trying to calculate the total invoice amount for different currencies in a  SAPScript.    I am running into a couple of  problems.
    1:  I cannot seem to find the exchange rate ( KURRF ) in KOMK/VBDKA or VBDKR, do you know where else the exhange rate would be populated?
    2: I cannot seem to use the commands: /: DEFINE &my_variable&
                                                                    /: &my_variable& = &KOMK-FKWRT& * &KOMK-KURRF& (pretend KURRF is populated)
                           is it even possible to do that sort of calculations in SAPScripts? if not, what is an easy way to accompolish this?
                          I only need to calculate this once.
    thank you.

    u can use FM to get the value in print program..and pass them to the sap script...
    The conversion rate is stored in TCURR table...
    CALL FUNCTION 'CONVERT_TO_FOREIGN_CURRENCY'
            EXPORTING
              date             = <fs_komv>-kdatu "<<date of convertion
              foreign_currency = komk-waerk
              local_amount     = wa_komp_o-netwr "<<value to convert
              local_currency   = <fs_komv>-waers
            IMPORTING
              foreign_amount   = <fs_komv>-kwert  "<<Converted value
            EXCEPTIONS
              no_rate_found    = 1
              overflow         = 2
              no_factors_found = 3
              no_spread_found  = 4
              derived_2_times  = 5
              OTHERS           = 6.

  • Regarding calculations in sapscript!very urgent

    friends...
    i have designed a form z_pm_common..which i have copied from standard.pm_common. i have made some changes to the layout.
    now at the header i have a field :
    DURATION OF JOB  :&AFVGD-ARBEI& &AFVGD-ARBEH&
    AFVGD-ARBEI IS WORK DURATION.I.E 6.3
    AFVGD-ARBEH IS UNIT. IN HOURS.
    THE WORK ENTERED IN IW33 ARE 1.0 , 2.0 , 6.3 AND UNIT IS H(hours)
    WHEN IAM USING  &AFVGD-ARBEI& &AFVGD-ARBEH&
    IAM GETTING ONLY THE LAST WORK I.E ( 6.3 H ).
    WHT I WANT TO DO IS CALCULATE 1.0 + 2.0 + 6.3 = 9.3. AND I WANT THE UNIT TO BE IN MINUTES. I.E THE O/P SHOULD BE LIKE 09:03 M(MINUTES).
    NOW HOW DO I MAKE THIS POSSIBLE ALSO HOW DO I PERFORM SUBROUTINE IN THIS CASE..PLZ TELL ME THE COMPLETE STEPS WITH CODING.
    I GUESS  IT WOULD BE PERFORM Z_PM_COMMON IN PROGRAM ZPMINCLUDE USING &WHAT&  CHANGING &WHAT?&
    THEN IN SUBROUTINE IT WOULD BE
    FORM Z_PM_COMMON WORKCONV_UNIT
        TABLES IN_TAB STRUCTURE ITCSY OUT_TAB STRUCTURE ITCSY.
         NOW WHT DO I DO....
    PLEASE SEND ME THE COMPLETE CODE....WHICH WORKS.......I WOULD BE GREATFULLL.
    I'LL GIVE U FULL POINTS IF I GET THE RIGHT SOLUTION..PLEASE HURRY.
    REGARDS
    ESSAM ([email protected])

    Hi,
    I got this from a link,
    Eg:
    Instead of: 
    /: BOX XPOS '11.21' MM  YPOS '5.31' MM  HEIGHT '10' MM WIDTH '20' MM INTENSITY 10 FRAME 0 TW
    You can write:
    /: POSITION XORIGIN '11.21' YORIGIN '5.31' MM
    /: SIZE HEIGHT '2' MM WIDTH '76' MM
    /: BOX  FRAME 10 TW INTENSITY 10
    This can be usefull if you gave several boxes that share the same parameters.
    HOPE IT HELPS U.
    Thanks&Regards,
    Ruthra

  • How to do calculation to a variable in Sapscript form

    Hi experts,
    My question looks simple but I failed to solve it. Supposed in the Sapscript form there are two variables: &it_tab-qty1&, &it_tab-qty2&. I need to add the first variable's value to the second one, I tried as below in Sapscript form editor:
    /: &it_tab-qty2& = &it_tab-qty2& + &it_tab-qty1&
    But it doesn't work. Could you please tell me the syntax to do such calculation in Sapscript? I cannot modify the print program so I have to modify the Sapscript form instead.
    Thanks a lot.
    Yu

    Yes, you need to write an external program using SE38 to perform the calculation.
    The syntax in SAPscript:
    /* all the var define in the SAPscript is char string type
    /: define &v1& = &it_tab-qty1&
    /: define &v2& = &it_tab-qty2&
    /: define &v3& = ''
    /* GET_COMPNAME is the form name & Z001 is the program name
    /: PERFORM GET_COMPNAME IN PROGRAM Z001
    /: USING &v1&
    /: USING &v2&
    /: CHANGING &v3&
    /: ENDPERFORM.
    The syntax in program Z001 (Created by SE38):
    REPORT ZFIR001.
    FORM GET_COMPNAME tables in_tab structure itcsy
                                                     out_tab structure itcsy.
      data : p_1 TYPE CHAR80,
               p_1 TYPE CHAR80,
               p_3 TYPE CHAR80.
      retrieve data from the SAPscript
        READ table in_tab index 1.
        MOVE in_tab-value to p_1.
        READ table in_tab index 2.
        MOVE in_tab-value to p_1.
      Write the code to convert p_1 & p_2 to numeric and perform the addition to p_3
      After that convert the p_3 to char.
      send data back to the SAPscript
        read table out_tab index 1.
        move p_3 to out_tab-value.
        modify out_tab index sy-tabix.
    ENDFORM.

  • Difference between FINT and F.24 for interest calculation

    Hi all!
    I am currently configuring the calculation of interest on arrears. To be more specific - an interest has to be calculated only on overdue items cleared with a payment. SAP advises to use F.24 transaction in this case. The problem is that F.24 doesn't produce a normal report where the clerks could see the invoices in a list (before actually posting the interest) - it produces the 'mail format' pages.
    I wonder what FINT transaction is for? Can I use it for calculating the interest on arrears? In SAP I didn't find any good documentation on this.
    Could you please help me by describing the main purpose of using the FINT? What is it for? Can it be used in my case?
    Thank you very much in advance!

    This is probably not as detailed as you would like but FINT is the replacement for F.24.  Both are still supported however there are several reporting advantages with FINT over F.24 specifically program RFINTITSHOW.  FINT also has additional selection capabilities and generally is an improved interest calculationprogram over F.24.  I can't off the top of my head think why they'd suggest to use F.24 now instead of FINT.  FINT I think also uses Smartforms where F.24 uses SAPScript (and can probably be made to use Smartforms) .
    Hope that helps somewhat.

  • Box in Long text of sapscript

    Hi All,
    I have  created a script.....in that i have to print  only long text in the main window.
    Now my problem is...the LONG text is breaking and going to next page...
    means a part on 1 page and remaining  on subsequent pages..
    And the problem is the box which i have put arround the main window is coming only in first page and last page .  In between pages the box arround the main window is not coming .
    How to get the box around those pages also.
    help me out...
    Thanks,
    Guru

    Hi
    The property of MAIN window is like that, If the Data is more than a Page it automatically goes to next pages.
    So better decide where I mean in which you wants to print ? In MAin window , then it automatcially goes to other pages. use a new paragraph format and mention PAGE PROTECTION for that such that it prints in the Same page.
    For the boxes see the seetings of the main window in all pages, especially in NEXT page.. so that the box is coming properly
    see the box related commands
    SAPScripts
    POSITION WINDOW
    SIZE WIDTH '160' MM HEIGHT '140' MM
    BOX FRAME 10 TW
    Box
    BOX HEIGHT '11' MM WIDTH '160' MM FRAME 10 TW INTENSITY 35
    linessssssss
    BOX XPOS '20' MM WIDTH 0 TW HEIGHT '140' MM FRAME 10 TW
    BOX XPOS '45' MM WIDTH 0 TW HEIGHT '140' MM FRAME 10 TW
    BOX XPOS '80' MM WIDTH 0 TW HEIGHT '140' MM FRAME 10 TW
    BOX XPOS '120' MM WIDTH 0 TW HEIGHT '140' MM FRAME 10 TW
    Boxes, Lines, Shading: BOX, POSITION, SIZE
    Use the BOX, POSITION, and SIZE commands for drawing boxes, lines, and shading to print particular windows within a form or passages of text within a window in a frame or with shading.
    The SAP printer drivers that are based on page-oriented printers (the HP LaserJet driver HPL2, the Postscript driver POST, the Kyocera Prescribe driver PRES) employ these commands when printing. Line printers and page-oriented printers not supported in the standard ignore these commands. You can view the resulting printer output in the SAPscript print preview.
    Syntax:
    /: BOX [XPOS] [YPOS] [WIDTH] [HEIGHT] [FRAME] [INTENSITY]
    /: POSITION [XORIGIN] [YORIGIN] [WINDOW] [PAGE]
    /: SIZE [WIDTH] [HEIGHT] [WINDOW] [PAGE]
    BOX Command
    Syntax
    /: BOX [XPOS] [YPOS] [WIDTH] [HEIGHT] [FRAME] [INTENSITY]
    Effect: draws a box of the specified size at the specified position.
    Parameters: For each of XPOS, YPOS, WIDTH, HEIGHT, and FRAME, you must specify both a measurement and a unit of measurement. Specify the INTENSITY parameter as a percentage between 0 and 100.
    XPOS, YPOS
    Upper left corner of the box, relative to the values of the POSITION command.
    Default: Values specified in the POSITION command.
    The following calculation is performed internally to determine the absolute output position of a box on the page:
    X(abs) = XORIGIN + XPOS
    Y(abs) = YORIGIN + YPOS
    WIDTH
    Width of the box. Default: WIDTH value of the SIZE command.
    HEIGHT
    Height of the box. Default: HEIGHT value of the SIZE command.
    FRAME
    Thickness of frame.
    Default: 0 (no frame).
    INTENSITY
    Grayscale of box contents as %.
    Default: 100 (full black)
    Measurements: You must specify decimal numbers as literal values (like ABAP numeric constants) by enclosing them in inverted commas. Use the period as the decimal point character. See also the examples listed below.
    Units of measurement: The following units of measurement may be used:
    TW (twip)
    PT (point)
    IN (inch)
    MM (millimeter)
    CM (centimeter)
    LN (line)
    CH (character).
    The following conversion factors apply:
    1 TW = 1/20 PT
    1 PT = 1/72 IN
    1 IN = 2.54 CM
    1 CM = 10 MM
    1 CH = height of a character relative to the CPI specification in the form header
    1 LN = height of a line relative to the LPI specification in the form header
    /: BOX FRAME 10 TW
    Draws a frame around the current window with a frame thickness of 10 TW (= 0.5 PT).
    /: BOX INTENSITY 10
    Fills the window background with shading having a gray scale of 10 %.
    /: BOX HEIGHT 0 TW FRAME 10 TW
    Draws a horizontal line across the complete top edge of the window.
    /: BOX WIDTH 0 TW FRAME 10 TW
    Draws a vertical line along the complete height of the left hand edge of the window.
    /: BOX WIDTH '17.5' CM HEIGHT 1 CM FRAME 10 TW INTENSITY 15
    /: BOX WIDTH '17.5' CM HEIGHT '13.5' CM FRAME 10 TW
    /: BOX XPOS '10.0' CM WIDTH 0 TW HEIGHT '13.5' CM FRAME 10 TW
    /: BOX XPOS '13.5' CM WIDTH 0 TW HEIGHT '13.5' CM FRAME 10 TW
    Draws two rectangles and two lines to construct a table of three columns with a highlighted heading section.
    POSITION Command
    Syntax
    /: POSITION [XORIGIN] [YORIGIN] [WINDOW] [PAGE]
    Effect: Sets the origin for the coordinate system used by the XPOS and YPOS parameters of the BOX command. When a window is first started, the POSITION value is set to refer to the upper left corner of the window (default setting).
    Parameters: If a parameter value does not have a leading sign, then its value is interpreted as an absolute value, in other words, as a value that specifies an offset from the upper left corner of the output page. If a parameter value is specified with a leading sign, then the new value of the parameter is calculated relative to the old value. If one of the parameter specifications is missing, then no change is made to this parameter.
    XORIGIN, YORIGIN
    Origin of the coordinate system.
    WINDOW
    Sets the values for the left and upper edges to match those of the current window (default setting).
    PAGE
    Sets the values for the left and upper edges to match those of the current output page (XORIGIN = 0 cm, YORIGIN = 0 cm).
    /: POSITION WINDOW
    Sets the origin for the coordinate system to the upper left corner of the window.
    /: POSITION XORIGIN 2 CM YORIGIN '2.5 CM'
    Sets the origin for the coordinate system to a point 2 cm from the left edge and 2.5 cm from the upper edge of the output page.
    /: POSITION XORIGIN '-1.5' CM YORIGIN -1 CM
    Shifts the origin for the coordinates 1.5 cm to the left and 1 cm up.
    SIZE Command
    Syntax
    /: SIZE [WIDTH] [HEIGHT] [WINDOW] [PAGE]
    Effect: Sets the values of the WIDTH and HEIGHT parameters used in the BOX command. When a window is first started, the SIZE value is set to the same values as the window itself (default setting).
    Parameters: If one of the parameter specifications is missing, then no change is made to the current value of this parameter. If a parameter value does not have a leading sign, then its value is interpreted as an absolute value. If a parameter value is specified with a leading sign, then the new value of the parameter is calculated relative to the old value.
    WIDTH, HEIGHT
    Dimensions of the rectangle or line.
    WINDOW
    Sets the values for the width and height to the values of the current window (default setting).
    PAGE
    Sets the values for the width and height to the values of the current output page.
    /: SIZE WINDOW
    Sets WIDTH and HEIGHT to the current window dimensions.
    /: SIZE WIDTH '3.5' CM HEIGHT '7.6' CM
    Sets WIDTH to 3.5 cm and HEIGHT to 7.6 cm.
    /: POSITION WINDOW
    /: POSITION XORIGIN -20 TW YORIGIN -20 TW
    /: SIZE WIDTH +40 TW HEIGHT +40 TW
    /: BOX FRAME 10 TW
    A frame is added to the current window. The edges of the frame extend beyond the edges of the window itself, so as to avoid obscuring the leading and trailing text characters.
    http://esnips.com/doc/1ff9f8e8-0a4c-42a7-8819-6e3ff9e7ab44/sapscripts.pdf
    http://esnips.com/doc/1e487f0c-8009-4ae1-9f9c-c07bd953dbfa/script-command.pdf
    http://esnips.com/doc/64d4eccb-e09b-48e1-9be9-e2818d73f074/faqss.pdf
    http://esnips.com/doc/cb7e39b4-3161-437f-bfc6-21e6a50e1b39/sscript.pdf
    http://esnips.com/doc/fced4d36-ba52-4df9-ab35-b3d194830bbf/symbols-in-scripts.pdf
    http://esnips.com/doc/b57e8989-ccf0-40d0-8992-8183be831030/sapscript-how-to-calculate-totals-and-subtotals.htm
    <b>Reward points for useful Answers</b>
    Regards
    Anji

  • Dynamic BOX in sapscript

    Hi,
    I am using the BOX control command in SapScript.
    Is it possible to assign the values of Xpos and Ypos
    dynamicalliy.
    In BOX XPOS 16 CH WIDTH 0 MM HEIGHT 18 MM FRAME 10 TW,
    i want to assign the values at runtime, instead of
    xpos 16 , something like Xpos Var, where var contain the value of xposition.
    or any other method to print dynamic box in sap script

    Hi
    yes it is possible
    see this
    SAPScripts
    POSITION WINDOW
    SIZE WIDTH '160' MM HEIGHT '140' MM
    BOX FRAME 10 TW
    Box
    BOX HEIGHT '11' MM WIDTH '160' MM FRAME 10 TW INTENSITY 35
    linessssssss
    BOX XPOS '20' MM WIDTH 0 TW HEIGHT '140' MM FRAME 10 TW
    BOX XPOS '45' MM WIDTH 0 TW HEIGHT '140' MM FRAME 10 TW
    BOX XPOS '80' MM WIDTH 0 TW HEIGHT '140' MM FRAME 10 TW
    BOX XPOS '120' MM WIDTH 0 TW HEIGHT '140' MM FRAME 10 TW
    Boxes, Lines, Shading: BOX, POSITION, SIZE
    Use the BOX, POSITION, and SIZE commands for drawing boxes, lines, and shading to print particular windows within a form or passages of text within a window in a frame or with shading.
    The SAP printer drivers that are based on page-oriented printers (the HP LaserJet driver HPL2, the Postscript driver POST, the Kyocera Prescribe driver PRES) employ these commands when printing. Line printers and page-oriented printers not supported in the standard ignore these commands. You can view the resulting printer output in the SAPscript print preview.
    Syntax:
    /: BOX [XPOS] [YPOS] [WIDTH] [HEIGHT] [FRAME] [INTENSITY]
    /: POSITION [XORIGIN] [YORIGIN] [WINDOW] [PAGE]
    /: SIZE [WIDTH] [HEIGHT] [WINDOW] [PAGE]
    BOX Command
    Syntax
    /: BOX [XPOS] [YPOS] [WIDTH] [HEIGHT] [FRAME] [INTENSITY]
    Effect: draws a box of the specified size at the specified position.
    Parameters: For each of XPOS, YPOS, WIDTH, HEIGHT, and FRAME, you must specify both a measurement and a unit of measurement. Specify the INTENSITY parameter as a percentage between 0 and 100.
    XPOS, YPOS
    Upper left corner of the box, relative to the values of the POSITION command.
    Default: Values specified in the POSITION command.
    The following calculation is performed internally to determine the absolute output position of a box on the page:
    X(abs) = XORIGIN + XPOS
    Y(abs) = YORIGIN + YPOS
    WIDTH
    Width of the box. Default: WIDTH value of the SIZE command.
    HEIGHT
    Height of the box. Default: HEIGHT value of the SIZE command.
    FRAME
    Thickness of frame.
    Default: 0 (no frame).
    INTENSITY
    Grayscale of box contents as %.
    Default: 100 (full black)
    Measurements: You must specify decimal numbers as literal values (like ABAP numeric constants) by enclosing them in inverted commas. Use the period as the decimal point character. See also the examples listed below.
    Units of measurement: The following units of measurement may be used:
    TW (twip)
    PT (point)
    IN (inch)
    MM (millimeter)
    CM (centimeter)
    LN (line)
    CH (character).
    The following conversion factors apply:
    1 TW = 1/20 PT
    1 PT = 1/72 IN
    1 IN = 2.54 CM
    1 CM = 10 MM
    1 CH = height of a character relative to the CPI specification in the form header
    1 LN = height of a line relative to the LPI specification in the form header
    /: BOX FRAME 10 TW
    Draws a frame around the current window with a frame thickness of 10 TW (= 0.5 PT).
    /: BOX INTENSITY 10
    Fills the window background with shading having a gray scale of 10 %.
    /: BOX HEIGHT 0 TW FRAME 10 TW
    Draws a horizontal line across the complete top edge of the window.
    /: BOX WIDTH 0 TW FRAME 10 TW
    Draws a vertical line along the complete height of the left hand edge of the window.
    /: BOX WIDTH '17.5' CM HEIGHT 1 CM FRAME 10 TW INTENSITY 15
    /: BOX WIDTH '17.5' CM HEIGHT '13.5' CM FRAME 10 TW
    /: BOX XPOS '10.0' CM WIDTH 0 TW HEIGHT '13.5' CM FRAME 10 TW
    /: BOX XPOS '13.5' CM WIDTH 0 TW HEIGHT '13.5' CM FRAME 10 TW
    Draws two rectangles and two lines to construct a table of three columns with a highlighted heading section.
    POSITION Command
    Syntax
    /: POSITION [XORIGIN] [YORIGIN] [WINDOW] [PAGE]
    Effect: Sets the origin for the coordinate system used by the XPOS and YPOS parameters of the BOX command. When a window is first started, the POSITION value is set to refer to the upper left corner of the window (default setting).
    Parameters: If a parameter value does not have a leading sign, then its value is interpreted as an absolute value, in other words, as a value that specifies an offset from the upper left corner of the output page. If a parameter value is specified with a leading sign, then the new value of the parameter is calculated relative to the old value. If one of the parameter specifications is missing, then no change is made to this parameter.
    XORIGIN, YORIGIN
    Origin of the coordinate system.
    WINDOW
    Sets the values for the left and upper edges to match those of the current window (default setting).
    PAGE
    Sets the values for the left and upper edges to match those of the current output page (XORIGIN = 0 cm, YORIGIN = 0 cm).
    /: POSITION WINDOW
    Sets the origin for the coordinate system to the upper left corner of the window.
    /: POSITION XORIGIN 2 CM YORIGIN '2.5 CM'
    Sets the origin for the coordinate system to a point 2 cm from the left edge and 2.5 cm from the upper edge of the output page.
    /: POSITION XORIGIN '-1.5' CM YORIGIN -1 CM
    Shifts the origin for the coordinates 1.5 cm to the left and 1 cm up.
    SIZE Command
    Syntax
    /: SIZE [WIDTH] [HEIGHT] [WINDOW] [PAGE]
    Effect: Sets the values of the WIDTH and HEIGHT parameters used in the BOX command. When a window is first started, the SIZE value is set to the same values as the window itself (default setting).
    Parameters: If one of the parameter specifications is missing, then no change is made to the current value of this parameter. If a parameter value does not have a leading sign, then its value is interpreted as an absolute value. If a parameter value is specified with a leading sign, then the new value of the parameter is calculated relative to the old value.
    WIDTH, HEIGHT
    Dimensions of the rectangle or line.
    WINDOW
    Sets the values for the width and height to the values of the current window (default setting).
    PAGE
    Sets the values for the width and height to the values of the current output page.
    /: SIZE WINDOW
    Sets WIDTH and HEIGHT to the current window dimensions.
    /: SIZE WIDTH '3.5' CM HEIGHT '7.6' CM
    Sets WIDTH to 3.5 cm and HEIGHT to 7.6 cm.
    /: POSITION WINDOW
    /: POSITION XORIGIN -20 TW YORIGIN -20 TW
    /: SIZE WIDTH +40 TW HEIGHT +40 TW
    /: BOX FRAME 10 TW
    A frame is added to the current window. The edges of the frame extend beyond the edges of the window itself, so as to avoid obscuring the leading and trailing text characters.
    http://esnips.com/doc/1ff9f8e8-0a4c-42a7-8819-6e3ff9e7ab44/sapscripts.pdf
    http://esnips.com/doc/1e487f0c-8009-4ae1-9f9c-c07bd953dbfa/script-command.pdf
    http://esnips.com/doc/64d4eccb-e09b-48e1-9be9-e2818d73f074/faqss.pdf
    http://esnips.com/doc/cb7e39b4-3161-437f-bfc6-21e6a50e1b39/sscript.pdf
    http://esnips.com/doc/fced4d36-ba52-4df9-ab35-b3d194830bbf/symbols-in-scripts.pdf
    http://esnips.com/doc/b57e8989-ccf0-40d0-8992-8183be831030/sapscript-how-to-calculate-totals-and-subtotals.htm
    Reward points for useful Answers
    Regards
    Anji

  • Box and Size stmt in sapscript

    Hi all
    a very basic question
    can anybody plz tell me whatz the difference between box and size stmt in sapscript
    Thanks in advance

    hi,
       Check this Out.....
       <b>BOX, POSITION, SIZE</b>: Boxes, lines, shading
    The BOX, POSITION and SIZE commands are for drawing boxes, lines and shadows. These commands can be used to specify that within any particular layout set, window or passage of window text can be output in a frame or with shadowing.
    The SAP printer drivers that are based on page-oriented printers (the HP LaserJet PCL-5 driver HPLJ4, the
    Postscript driver POST, the Kyocera Prescribe driver PRES) employ these commands when creating output. Line printers and non-supported page-oriented printers ignore these commands. The resulting output may be viewed in the SAPscript print previewer.
    Syntax:
    1. /: BOX [XPOS] [YPOS] [WIDTH] [HEIGHT] [FRAME] [INTENSITY]
    2. /: POSITION [XORIGIN] [YORIGIN] [WINDOW] [PAGE]
    3. /: SIZE [WIDTH] [HEIGHT] [WINDOW] [PAGE]
    <b>BOX</b>
    Syntax:
    /: BOX [XPOS] [YPOS] [WIDTH] [HEIGHT] [FRAME] [INTENSITY]
    Effect: draws a box of the specified size at the specified position.
    Parameters: For each parameter (XPOS, YPOS, WIDTH, HEIGHT and FRAME), both a measurement and a unit of measure must be specified. The INTENSITY parameter should be entered as a percentage between 0 and 100.
    •&#61472;XPOS, YPOS: Upper left corner of the box, relative to the values of the POSITION command.
    Default: Values specified in the POSITION command.
    The following calculation is performed internally to determine the absolute output position of a box on the page:
    X(abs) = XORIGIN + XPOS
    Y(abs) = YORIGIN + YPOS
    •&#61472;WIDTH: Width of the box.
    Default: WIDTH value of the SIZE command.
    •&#61472;HEIGHT: Height of the box.
    Default: HEIGHT value of the SIZE command.
    •&#61472;FRAME: Thickness of frame.
    Default: 0 (no frame).
    •&#61472;INTENSITY: Grayscale of box contents as %.
    Default: 100 (full black)
    Measurements: Decimal numbers must be specified as literal values (like ABAP/4 numeric constants) by being enclosed in inverted commas. The period should be used as the decimal point character. See also the examples listed below.
    Units of measure: The following units of measure may be used:
    •&#61472;TW (twip)
    •&#61472;PT (point)
    •&#61472;IN (inch)
    •&#61472;MM (millimeter)
    •&#61472;CM (centimeter)
    •&#61472;LN (line)
    •&#61472;CH (character).
    The following conversion factors apply:
    •&#61472;1 TW = 1/20 PT
    •&#61472;1 PT = 1/72 IN
    •&#61472;1 IN = 2.54 CM
    •&#61472;1 CM = 10 MM
    •&#61472;1 CH = height of a character relative to the CPI specification in the layout set header
    •&#61472;1 LN = height of a line relative to the LPI specification in the layout set header
    Examples:
    /: BOX FRAME 10 TW
    Draws a frame around the current window with a frame thickness of 10 TW (= 0.5 PT).
    /: BOX INTENSITY 10
    Fills the window background with shadowing having a gray scale of 10 %.
    /: BOX HEIGHT 0 TW FRAME 10 TW
    Draws a horizontal line across the complete top edge of the window.
    /: BOX WIDTH 0 TW FRAME 10 TW
    Draws a vertical line along the complete height of the left hand edge of the window.
    /: BOX WIDTH '17.5' CM HEIGHT 1 CM FRAME 10 TW INTENSITY 15
    /: BOX WIDTH '17.5' CM HEIGHT '13.5' CM FRAME 10 TW
    /: BOX XPOS '10.0' CM WIDTH 0 TW HEIGHT '13.5' CM FRAME 10 TW
    /: BOX XPOS '13.5' CM WIDTH 0 TW HEIGHT '13.5' CM FRAME 10 TW
    Draws two rectangles and two lines to construct a table of three columns with a highlighted heading section.
    POSITION
    Syntax:
    /: POSITION [XORIGIN] [YORIGIN] [WINDOW] [PAGE]
    Effect: Sets the origin for the coordinate system used by the XPOS and YPOS parameters of the BOX command. When a window is first started the POSITION value is set to refer to the upper left corner of the window (default setting).
    Parameters: If a parameter value does not have a leading sign, then its value is interpreted as an absolute value, in other words as a value which specifies an offset from the upper left corner of the output page. If a parameter value is specified with a leading sign, then the new value of the parameter is calculated relative to the old value. If one of the parameter specifications is missing, then no change is made to this parameter.
    •&#61472;XORIGIN, YORIGIN: Origin of the coordinate system.
    •&#61472;WINDOW: Sets the values for the left and upper edges to be the same of those of the current window (default setting).
    •&#61472;PAGE: Sets the values for the left and upper edges to be the same as those of the current output page (XORIGIN = 0 cm, YORIGIN = 0 cm).
    Examples:
    /: POSITION WINDOW
    Sets the origin for the coordinate system to the upper left corner of the window.
    /: POSITION XORIGIN 2 CM YORIGIN '2.5 CM'
    Sets the origin for the coordinate system to a point 2 cm from the left edge and 2.5 cm from the upper edge of the output page.
    /: POSITION XORIGIN '-1.5' CM YORIGIN -1 CM
    Shifts the origin for the coordinates 1.5 cm to the left and 1 cm up.
    <b>SIZE</b>
    Syntax:
    /: SIZE [WIDTH] [HEIGHT] [WINDOW] [PAGE]
    Effect: Sets the values of the WIDTH and HEIGHT parameters used in the BOX command. When a window is first started the SIZE value is set to the same values as the window itself (default setting).
    Parameters: If one of the parameter specifications is missing, then no change is made to the current value of this parameter. If a parameter value does not have a leading sign, then its value is interpreted as an absolute value. If a parameter value is specified with a leading sign, then the new value of the parameter is calculated relative to the old value.
    •&#61472;WIDTH, HEIGHT: Dimensions of the rectangle or line.
    •&#61472;WINDOW: Sets the values for the width and height to the values of the current window (default setting).
    •&#61472;PAGE: Sets the values for the width and height to the values of the current output page.
    Examples:
    /: SIZE WINDOW
    Sets WIDTH and HEIGHT to the current window dimensions.
    /: SIZE WIDTH '3.5' CM HEIGHT '7.6' CM
    Sets WIDTH to 3.5 cm and HEIGHT to 7.6 cm.
    /: POSITION WINDOW
    /: POSITION XORIGIN -20 TW YORIGIN -20 TW
    /: SIZE WIDTH +40 TW HEIGHT +40 TW
    /: BOX FRAME 10 TW
    A frame is added to the current window. The edges of the frame extend beyond the edges of the window itself, so as to avoid obscuring the leading and trailing text characters.
    Regards,
    Santosh

  • Draw tables in sapscript

    How to draw the tables in sapscript?
    Is there any other way then draw box for vetical and horizontal line.

    Hi
    See this and draw the boxes in Script
    SAPScripts
    http://esnips.com/doc/1ff9f8e8-0a4c-42a7-8819-6e3ff9e7ab44/sapscripts.pdf
    http://esnips.com/doc/1e487f0c-8009-4ae1-9f9c-c07bd953dbfa/script-command.pdf
    http://esnips.com/doc/64d4eccb-e09b-48e1-9be9-e2818d73f074/faqss.pdf
    http://esnips.com/doc/cb7e39b4-3161-437f-bfc6-21e6a50e1b39/sscript.pdf
    http://esnips.com/doc/fced4d36-ba52-4df9-ab35-b3d194830bbf/symbols-in-scripts.pdf
    http://esnips.com/doc/b57e8989-ccf0-40d0-8992-8183be831030/sapscript-how-to-calculate-totals-and-subtotals.htm
    POSITION WINDOW
    SIZE WIDTH '160' MM HEIGHT '140' MM
    BOX FRAME 10 TW
    Box
    BOX HEIGHT '11' MM WIDTH '160' MM FRAME 10 TW INTENSITY 35
    linessssssss
    BOX XPOS '20' MM WIDTH 0 TW HEIGHT '140' MM FRAME 10 TW
    BOX XPOS '45' MM WIDTH 0 TW HEIGHT '140' MM FRAME 10 TW
    BOX XPOS '80' MM WIDTH 0 TW HEIGHT '140' MM FRAME 10 TW
    BOX XPOS '120' MM WIDTH 0 TW HEIGHT '140' MM FRAME 10 TW
    Boxes, Lines, Shading: BOX, POSITION, SIZE
    Use the BOX, POSITION, and SIZE commands for drawing boxes, lines, and shading to print particular windows within a form or passages of text within a window in a frame or with shading.
    The SAP printer drivers that are based on page-oriented printers (the HP LaserJet driver HPL2, the Postscript driver POST, the Kyocera Prescribe driver PRES) employ these commands when printing. Line printers and page-oriented printers not supported in the standard ignore these commands. You can view the resulting printer output in the SAPscript print preview.
    Syntax:
    /: BOX [XPOS] [YPOS] [WIDTH] [HEIGHT] [FRAME] [INTENSITY]
    /: POSITION [XORIGIN] [YORIGIN] [WINDOW] [PAGE]
    /: SIZE [WIDTH] [HEIGHT] [WINDOW] [PAGE]
    BOX Command
    Syntax
    /: BOX [XPOS] [YPOS] [WIDTH] [HEIGHT] [FRAME] [INTENSITY]
    Effect: draws a box of the specified size at the specified position.
    Parameters: For each of XPOS, YPOS, WIDTH, HEIGHT, and FRAME, you must specify both a measurement and a unit of measurement. Specify the INTENSITY parameter as a percentage between 0 and 100.
    XPOS, YPOS
    Upper left corner of the box, relative to the values of the POSITION command.
    Default: Values specified in the POSITION command.
    The following calculation is performed internally to determine the absolute output position of a box on the page:
    X(abs) = XORIGIN + XPOS
    Y(abs) = YORIGIN + YPOS
    WIDTH
    Width of the box. Default: WIDTH value of the SIZE command.
    HEIGHT
    Height of the box. Default: HEIGHT value of the SIZE command.
    FRAME
    Thickness of frame.
    Default: 0 (no frame).
    INTENSITY
    Grayscale of box contents as %.
    Default: 100 (full black)
    Measurements: You must specify decimal numbers as literal values (like ABAP numeric constants) by enclosing them in inverted commas. Use the period as the decimal point character. See also the examples listed below.
    Units of measurement: The following units of measurement may be used:
    TW (twip)
    PT (point)
    IN (inch)
    MM (millimeter)
    CM (centimeter)
    LN (line)
    CH (character).
    The following conversion factors apply:
    1 TW = 1/20 PT
    1 PT = 1/72 IN
    1 IN = 2.54 CM
    1 CM = 10 MM
    1 CH = height of a character relative to the CPI specification in the form header
    1 LN = height of a line relative to the LPI specification in the form header
    /: BOX FRAME 10 TW
    Draws a frame around the current window with a frame thickness of 10 TW (= 0.5 PT).
    /: BOX INTENSITY 10
    Fills the window background with shading having a gray scale of 10 %.
    /: BOX HEIGHT 0 TW FRAME 10 TW
    Draws a horizontal line across the complete top edge of the window.
    /: BOX WIDTH 0 TW FRAME 10 TW
    Draws a vertical line along the complete height of the left hand edge of the window.
    /: BOX WIDTH '17.5' CM HEIGHT 1 CM FRAME 10 TW INTENSITY 15
    /: BOX WIDTH '17.5' CM HEIGHT '13.5' CM FRAME 10 TW
    /: BOX XPOS '10.0' CM WIDTH 0 TW HEIGHT '13.5' CM FRAME 10 TW
    /: BOX XPOS '13.5' CM WIDTH 0 TW HEIGHT '13.5' CM FRAME 10 TW
    Draws two rectangles and two lines to construct a table of three columns with a highlighted heading section.
    POSITION Command
    Syntax
    /: POSITION [XORIGIN] [YORIGIN] [WINDOW] [PAGE]
    Effect: Sets the origin for the coordinate system used by the XPOS and YPOS parameters of the BOX command. When a window is first started, the POSITION value is set to refer to the upper left corner of the window (default setting).
    Parameters: If a parameter value does not have a leading sign, then its value is interpreted as an absolute value, in other words, as a value that specifies an offset from the upper left corner of the output page. If a parameter value is specified with a leading sign, then the new value of the parameter is calculated relative to the old value. If one of the parameter specifications is missing, then no change is made to this parameter.
    XORIGIN, YORIGIN
    Origin of the coordinate system.
    WINDOW
    Sets the values for the left and upper edges to match those of the current window (default setting).
    PAGE
    Sets the values for the left and upper edges to match those of the current output page (XORIGIN = 0 cm, YORIGIN = 0 cm).
    /: POSITION WINDOW
    Sets the origin for the coordinate system to the upper left corner of the window.
    /: POSITION XORIGIN 2 CM YORIGIN '2.5 CM'
    Sets the origin for the coordinate system to a point 2 cm from the left edge and 2.5 cm from the upper edge of the output page.
    /: POSITION XORIGIN '-1.5' CM YORIGIN -1 CM
    Shifts the origin for the coordinates 1.5 cm to the left and 1 cm up.
    SIZE Command
    Syntax
    /: SIZE [WIDTH] [HEIGHT] [WINDOW] [PAGE]
    Effect: Sets the values of the WIDTH and HEIGHT parameters used in the BOX command. When a window is first started, the SIZE value is set to the same values as the window itself (default setting).
    Parameters: If one of the parameter specifications is missing, then no change is made to the current value of this parameter. If a parameter value does not have a leading sign, then its value is interpreted as an absolute value. If a parameter value is specified with a leading sign, then the new value of the parameter is calculated relative to the old value.
    WIDTH, HEIGHT
    Dimensions of the rectangle or line.
    WINDOW
    Sets the values for the width and height to the values of the current window (default setting).
    PAGE
    Sets the values for the width and height to the values of the current output page.
    /: SIZE WINDOW
    Sets WIDTH and HEIGHT to the current window dimensions.
    /: SIZE WIDTH '3.5' CM HEIGHT '7.6' CM
    Sets WIDTH to 3.5 cm and HEIGHT to 7.6 cm.
    /: POSITION WINDOW
    /: POSITION XORIGIN -20 TW YORIGIN -20 TW
    /: SIZE WIDTH +40 TW HEIGHT +40 TW
    /: BOX FRAME 10 TW
    A frame is added to the current window. The edges of the frame extend beyond the edges of the window itself, so as to avoid obscuring the leading and trailing text characters.
    Reward points if useful
    Regards
    Anji

  • Using a perform in a form with sapscript

    Hi,
    I would like to print a field during the runtime  in a form. This field it is not available in the program so i would like to find it using a perform in the sapcript.
    Someone tell me that this is possible...but someone can tell me how? Is there some docs about this issue?
               Best Regards
                    João Fernandes

    Hi,
    following is the help link...
    http://help.sap.com/saphelp_nw70/helpdata/en/d1/803279454211d189710000e8322d00/frameset.htm
    Calling ABAP Subroutines: PERFORM 
    You can use the PERFORM command to call an ABAP subroutine (form) from any program, subject to the normal ABAP runtime authorization checking. You can use such calls to subroutines for carrying out calculations, for obtaining data from the database that is needed at display or print time, for formatting data, and so on.
    PERFORM commands, like all control commands, are executed when a document is formatted for display or printing. Communication between a subroutine that you call and the document is by way of symbols whose values are set in the subroutine.
    The system does not execute the PERFORM command within SAPscript replace modules, such as TEXT_SYMBOL_REPLACE or TEXT_INCLUDE_REPLACE. The replace modules can only replace symbol values or resolve include texts, but not interpret SAPscript control commands.
    Syntax in a form window:
    /: PERFORM <form> IN PROGRAM <prog>
    /: USING &INVAR1&
    /: USING &INVAR2&
    /: CHANGING &OUTVAR1&
    /: CHANGING &OUTVAR2&
    /: ENDPERFORM
    INVAR1 and INVAR2 are variable symbols and may be of any of the four SAPscript symbol types.
    OUTVAR1 and OUTVAR2 are local text symbols and must therefore be character strings.
    The ABAP subroutine called via the command line stated above must be defined in the ABAP report prog as follows:
    FORM <form> TABLES IN_TAB STRUCTURE ITCSY
    OUT_TAB STRUCTURE ITCSY.
    ENDFORM.
    The values of the SAPscript symbols passed with /: USING... are now stored in the internal table IN_TAB . Note that the system passes the values as character string to the subroutine, since the field Feld VALUE in structure ITCSY has the domain TDSYMVALUE (CHAR 80). See the example below on how to access the variables.
    The internal table OUT_TAB contains names and values of the CHANGING parameters in the PERFORM statement. These parameters are local text symbols, that is, character fields. See the example below on how to return the variables within the subroutine.
    From within a SAPscript form, a subroutine GET_BARCODE in the ABAP program QCJPERFO is called. Then the simple barcode contained there (‘First page’, ‘Next page’, ‘Last page’) is printed as local variable symbol.
    Definition in the SAPscript form:
    /: PERFORM GET_BARCODE IN PROGRAM QCJPERFO
    /: USING &PAGE&
    /: USING &NEXTPAGE&
    /: CHANGING &BARCODE&
    /: ENDPERFORM
    / &BARCODE&
    Coding of the calling ABAP program:
    REPORT QCJPERFO.
    FORM GET_BARCODE TABLES IN_PAR STUCTURE ITCSY
    OUT_PAR STRUCTURE ITCSY.
    DATA: PAGNUM LIKE SY-TABIX, "page number
    NEXTPAGE LIKE SY-TABIX. "number of next page
    READ TABLE IN_PAR WITH KEY ‘PAGE’.
    CHECK SY-SUBRC = 0.
    PAGNUM = IN_PAR-VALUE.
    READ TABLE IN_PAR WITH KEY ‘NEXTPAGE’.
    CHECK SY-SUBRC = 0.
    NEXTPAGE = IN_PAR-VALUE.
    READ TABLE OUT_PAR WITH KEY ‘BARCODE’.
    CHECK SY-SUBRC = 0.
    IF PAGNUM = 1.
    OUT_PAR-VALUE = ‘|’. "First page
    ELSE.
    OUT_PAR-VALUE = ‘||’. "Next page
    ENDIF.
    IF NEXTPAGE = 0.
    OUT_PAR-VALUE+2 = ‘L’. "Flag: last page
    ENDIF.
    MODIFY OUT_PAR INDEX SY-TABIX.
    ENDFORM.
    Regards,
    Bharat.

  • REGION is not shown in Address to be printed in SAPSCRIPT

    Hi,
           I am trying to print the address within a sapscript .Everything is being displayed except the 'regio' ie region field. but when i replace the label region with city or something else followed by the field name it prints fine.
    The code is as follows:
    ADDRESS DELIVERY PARAGRAPH L
      TITLE    &VBDKL-KUNWE&
      NAME     &VBDKL-NAME1&, &VBDKL-NAME2&, &VBDKL-NAME3&,&VBDKL-NAME4&
      STREET   &VBDKL-STRAS&
      CITY     &VBDKL-ORT01&
      POSTCODE &VBDKL-PSTLZ&
      REGION   &VBDKL-REGIO&
      COUNTRY  &VBDKL-LAND1&
      FROMCOUNTRY 'FR '
    ENDADDRESS

    Check this out once -
    Formatting Addresses: ADDRESS
    The ADDRESS - ENDADDRESS control command formats an address according to the postal convention of the recipient country defined in the COUNTRY parameter. The reference fields are described in the structures ADRS1, ADRS2, or ADRS3, depending on the type of address. Either direct values or symbols may be assigned to the parameters.
    Syntax:
    /: ADDRESS [DELIVERY] [TYPE t] [PARAGRAPH a] [PRIORITY p] [LINES l]
    /: TITLE title
    /: NAME name1[,name2[,name3[,name4]]]
    /: PERSON name of natural person [TITLE form of address]
    /: PERSONNUMBER number of the personen
    /: DEPARTMENT department
    /: STREET street name HOUSE house number
    /: LOCATION additional location information
    /: POBOX po box [CODE post code / zip code] [CITY city]
    /: POSTCODE post code / zip_code
    /: CITY city1[,city2]
    /: NO_UPPERCASE_FOR_CITY
    /: REGION county / state
    /: COUNTRY recipient country [LANGUAGE language code]
    /: COUNTRY_IN_REC_LANG
    /: LANG_FOR_COUNTRY language key
    /: FROMCOUNTRY sender country
    /: ADDRESSNUMBER address number
    /: ENDADDRESS
    The parameter values contain both formatting and address information. The address data are formatted for output according to the data in the following parameters:
    TYPE
    FROMCOUNTRY
    COUNTRY
    LANGUAGE
    PRIORITY
    DELIVERY
    LINES
    For more information, see the documentation for the SAP function module ADDRESS_INTO_PRINTFORM.
    If DELIVERY is not specified and if a POBOX is specified, then the POBOX is used in an address instead of a STREET.
    Parameters
    DELIVERY
    Means that the address should be formatted as a complete delivery address, using the street name and number rather than the P.O. Box.
    TYPE
    Specifies the type of address. The following types are possible:
    1.     Normal address (ADRS1). This is the address of a company or organization. It corresponds to the address structure that is expected in most SAP applications.
    2.     Private or personal address (ADRS2). This is the address of a natural person, a private or home address.
    3.     Company addressDienstadresse (ADRS3) with contact person. This is the address of a colleague or contact within a company or organization. The company name should be specified in the TITLE and NAME fields; the ATTN: contact person should be named in PERSON and TITLE.
    Should you enter another address type or leave the field blank, then type 1 is used for formatting.
    PARAGRAPH
    Specifies the paragraph format to be used for outputting the address. If this parameter is not given, the address will be output using the default paragraph format.
    PRIORITY
    Specifies which of the address lines may be omitted should this be necessary. Any combination of the following codes may be specified. The order in which you list the codes determines the order in which address lines are left out.
    The codes are as follows:
    A Title
    P Mandatory empty line
    4 Name4
    3 Name3
    R Region
    T Neighborhood, administrative section of a city (CITY2)l
    D Department
    L Country name
    C Post code or zip code
    2 Name2
    B P.O. Box (Japan only)
    S Street name and number or P.O. Box, depending upon DELIVERY parameter
    N Name and form of address of natural person (PERSON and TITLE)
    I Location information in LOCATION
    O City
    LINES
    Specifies how many lines may be used for formatting the address. If there are too few lines available to allow all the address data to be formatted, then the data specified in the PRIORITY parameter are omitted. If there is no LINES parameter and if this command is in a form window of a type other than MAIN, then the number of lines available for formatting the address are automatically calculated based on the current output position and the size of the window.
    TITLE
    Title or form of address. Used only with addresses of types 1 and 3.
    NAME
    Up to four names may be given, separated by commas. Used only with addresses of types 1 and 3.
    PERSON
    Name of the addressee. Used only for addresses of type 2 (private or personal address) or type 3 (company contact address). In type 3 addresses, use PERSON for the name of your contact person: ‘Attn: Mr. Jeffries’. The name fields should be used for the company address.
    PERSONNUMBER
    Personal number. Can be used only for address types 2 or 3 (private or personal address).
    TITLE (with PERSON)
    Title of the addressee. Can be used only for address types 2 or type 3 (private or personal address).
    DEPARTMENT
    Department of the addressee. Can be used only for address type 3 (company address).
    STREET
    Street name.
    HOUSE
    House number for the corresponding street.
    LOCATION
    Additional location information, such as the building, "Upstairs Apartment" and so on. Appears on its own line in the address.
    POBOX
    P. O. Box
    CODE
    The post code / zip code of the P. O. Box if this differs from the post code / zip code of the recipient.
    CITY
    The city in which the destination P.O. Box is located if this differs from the city of the recipient.
    POSTCODE
    Post code / zip code of the recipient.
    CITY
    Addressee’s city. city1 is expected to be the city; city2 is the neighborhood or administrative section, if required.
    NO_UPPERCASE_FOR_CITY
    Default = NO_UPPERCASE_FOR_CITY ‘ ‘
    Usually, the system prints the city and country names of foreign addresses in uppercase ( NO_UPPERCASE_FOR_CITY ‘ ‘ ).
    You can use this parameter to force the system to output city and country name unchanged (uppercase/lowercase).
    ( NO_UPPERCASE_FOR_CITY ‘X’ )
    REGION
    This allows an administrative region, county, province, or state etc. to be specified.
    COUNTRY
    Specifies the recipient country, i.e. the country according to whose postal conventions the address is to be formatted.
    COUNTRY_IN_REC_LANG
    This flag tells the system to use the recipient language for the country name.
    ( COUNTRY_IN_REC_LANG ‘X‘ )
    ( Default: Recipient language is not used: COUNTRY_IN_REC_LANG ‘ ‘ )
    LANG_FOR_COUNTRY
    Default = Space
    Use this parameter to explicitly set the language in which to print the country name of a foreign address. By default, the system uses the language of the sending country.
    LANGUAGE
    Language code of the language of the recipient country, if it differs from that of the recipient COUNTRY. Example: addresses in Switzerland. Standard SAP language codes are used; you can display these in the initial SAPscript text processing screen or in table T002.
    FROMCOUNTRY
    Specifies the language to be used for formatting the name of the recipient country. For most European countries, the recipient country is specified by placing the international car registration letters in front of the post code and separating them from the post code with a hyphen. You must always specify the sender country.
    ADDRESSNUMBER
    The number is used to index a central address file, from which the desired address is read instead of using the set of the above fields. You can find more information on this facility in the documentation for the function module ADDRESS_INTO_PRINTFORM.
    You use this one parameter instead of the set of parameters described before.
    /: ADDRESS
    /: TITLE 'Firma'
    /: NAME 'Schneider & Co', 'Finanzberatung'
    /: STREET 'Kapitalgasse 33'
    /: POBOX '12345' CODE '68499'
    /: POSTCODE '68309'
    /: CITY 'Mannheim'
    /: COUNTRY 'DE'
    /: FROMCOUNTRY 'DE'
    /: ENDADDRESS
    This produces the following output address:
    Firma
    Schneider & Co
    Finanzberatung
    Postfach 12345
    68499 Mannheim
    If the DELIVERY parameter is specified on the ADDRESS command, then the street name and number will appear in the address in place of the P. O. Box number.
    Firma
    Schneider & Co
    Finanzberatung
    Kapitalgasse 33
    68309 Mannheim
    SAPscript makes an internal call to the ADDRESS_INTO_PRINTFORM function module for formatting the address. If the result is not as expected, you should check the settings for this function module (see the function module documentation).

  • How to Draw table in SAPscript ???

    Hi all Guru of SAPScript!
    I want to draw a table with column and row in SAPscript. Who can help me step by step?
    Thanks!
    Edited by: kathy a on May 6, 2008 11:53 AM

    Hi,
    Use BOx Syantax  How to Draw table in SAPscript ??? Pls Read the description
    Syntax:
    1. /: BOX [XPOS] [YPOS] [WIDTH] [HEIGHT] [FRAME] [INTENSITY]
    2. /: POSITION [XORIGIN] [YORIGIN] [WINDOW] [PAGE]
    3. /: SIZE [WIDTH] [HEIGHT] [WINDOW] [PAGE]
    BOX
    Syntax:
    /: BOX [XPOS] [YPOS] [WIDTH] [HEIGHT] [FRAME] [INTENSITY]
    Effect: draws a box of the specified size at the specified position.
    Parameters: For each parameter (XPOS, YPOS, WIDTH, HEIGHT and FRAME), both a measurement and a unit of measure must be specified. The INTENSITY parameter should be entered as a percentage between 0 and 100.
    •&#61472;XPOS, YPOS: Upper left corner of the box, relative to the values of the POSITION command.
    Default: Values specified in the POSITION command.
    The following calculation is performed internally to determine the absolute output position of a box on the page:
    X(abs) = XORIGIN + XPOS
    Y(abs) = YORIGIN + YPOS
    •&#61472;WIDTH: Width of the box.
    Default: WIDTH value of the SIZE command.
    •&#61472;HEIGHT: Height of the box.
    Default: HEIGHT value of the SIZE command.
    •&#61472;FRAME: Thickness of frame.
    Default: 0 (no frame).
    •&#61472;INTENSITY: Grayscale of box contents as %.
    Default: 100 (full black)
    Measurements: Decimal numbers must be specified as literal values (like ABAP/4 numeric constants) by being enclosed in inverted commas. The period should be used as the decimal point character. See also the examples listed below.
    Units of measure: The following units of measure may be used:
    •&#61472;TW (twip)
    •&#61472;PT (point)
    •&#61472;IN (inch)
    •&#61472;MM (millimeter)
    •&#61472;CM (centimeter)
    •&#61472;LN (line)
    •&#61472;CH (character).
    The following conversion factors apply:
    •&#61472;1 TW = 1/20 PT
    •&#61472;1 PT = 1/72 IN
    •&#61472;1 IN = 2.54 CM
    •&#61472;1 CM = 10 MM
    •&#61472;1 CH = height of a character relative to the CPI specification in the layout set header
    •&#61472;1 LN = height of a line relative to the LPI specification in the layout set header
    Examples:
    /: BOX FRAME 10 TW
    Draws a frame around the current window with a frame thickness of 10 TW (= 0.5 PT).
    /: BOX INTENSITY 10
    Fills the window background with shadowing having a gray scale of 10 %.
    /: BOX HEIGHT 0 TW FRAME 10 TW
    Draws a horizontal line across the complete top edge of the window.
    /: BOX WIDTH 0 TW FRAME 10 TW
    Draws a vertical line along the complete height of the left hand edge of the window.
    /: BOX WIDTH '17.5' CM HEIGHT 1 CM FRAME 10 TW INTENSITY 15
    /: BOX WIDTH '17.5' CM HEIGHT '13.5' CM FRAME 10 TW
    /: BOX XPOS '10.0' CM WIDTH 0 TW HEIGHT '13.5' CM FRAME 10 TW
    /: BOX XPOS '13.5' CM WIDTH 0 TW HEIGHT '13.5' CM FRAME 10 TW
    Draws two rectangles and two lines to construct a table of three columns with a highlighted heading section.
    POSITION
    Syntax:
    /: POSITION [XORIGIN] [YORIGIN] [WINDOW] [PAGE]
    Effect: Sets the origin for the coordinate system used by the XPOS and YPOS parameters of the BOX command. When a window is first started the POSITION value is set to refer to the upper left corner of the window (default setting).
    Parameters: If a parameter value does not have a leading sign, then its value is interpreted as an absolute value, in other words as a value which specifies an offset from the upper left corner of the output page. If a parameter value is specified with a leading sign, then the new value of the parameter is calculated relative to the old value. If one of the parameter specifications is missing, then no change is made to this parameter.
    •&#61472;XORIGIN, YORIGIN: Origin of the coordinate system.
    •&#61472;WINDOW: Sets the values for the left and upper edges to be the same of those of the current window (default setting).
    •&#61472;PAGE: Sets the values for the left and upper edges to be the same as those of the current output page (XORIGIN = 0 cm, YORIGIN = 0 cm).
    Examples:
    /: POSITION WINDOW
    Sets the origin for the coordinate system to the upper left corner of the window.
    /: POSITION XORIGIN 2 CM YORIGIN '2.5 CM'
    Sets the origin for the coordinate system to a point 2 cm from the left edge and 2.5 cm from the upper edge of the output page.
    /: POSITION XORIGIN '-1.5' CM YORIGIN -1 CM
    Shifts the origin for the coordinates 1.5 cm to the left and 1 cm up.
    SIZE
    Syntax:
    /: SIZE [WIDTH] [HEIGHT] [WINDOW] [PAGE]
    Effect: Sets the values of the WIDTH and HEIGHT parameters used in the BOX command. When a window is first started the SIZE value is set to the same values as the window itself (default setting).
    Parameters: If one of the parameter specifications is missing, then no change is made to the current value of this parameter. If a parameter value does not have a leading sign, then its value is interpreted as an absolute value. If a parameter value is specified with a leading sign, then the new value of the parameter is calculated relative to the old value.
    •&#61472;WIDTH, HEIGHT: Dimensions of the rectangle or line.
    •&#61472;WINDOW: Sets the values for the width and height to the values of the current window (default setting).
    •&#61472;PAGE: Sets the values for the width and height to the values of the current output page.
    Examples:
    /: SIZE WINDOW
    Sets WIDTH and HEIGHT to the current window dimensions.
    /: SIZE WIDTH '3.5' CM HEIGHT '7.6' CM
    Sets WIDTH to 3.5 cm and HEIGHT to 7.6 cm.
    /: POSITION WINDOW
    /: POSITION XORIGIN -20 TW YORIGIN -20 TW
    /: SIZE WIDTH +40 TW HEIGHT +40 TW
    /: BOX FRAME 10 TW
    A frame is added to the current window. The edges of the frame extend beyond the edges of the window itself, so as to avoid obscuring the leading and trailing text characters.
    Reward Helpfull Answers
    Regards
    Fareedas

  • Reports in SAPScripts

    Please anybody tell me how to call reports in SAP Scripts?

    Hi,
      You can use the PERFORM command to call an ABAP subroutine (form) from any program, subject to the normal ABAP runtime authorization checking. You can use such calls to subroutines for carrying out calculations, for obtaining data from the database that is needed at display or print time, for formatting data, and so on.
    PERFORM commands, like all control commands, are executed when a document is formatted for display or printing. Communication between a subroutine that you call and the document is by way of symbols whose values are set in the subroutine.
    The system does not execute the PERFORM command within SAPscript replace modules, such as TEXT_SYMBOL_REPLACE or TEXT_INCLUDE_REPLACE. The replace modules can only replace symbol values or resolve include texts, but not interpret SAPscript control commands.
    Syntax in a form window:
    /: PERFORM <form> IN PROGRAM <prog>
    /: USING &INVAR1&
    /: USING &INVAR2&
    /: CHANGING &OUTVAR1&
    /: CHANGING &OUTVAR2&
    /: ENDPERFORM
    INVAR1 and INVAR2 are variable symbols and may be of any of the four SAPscript symbol types.
    OUTVAR1 and OUTVAR2 are local text symbols and must therefore be character strings.
    The ABAP subroutine called via the command line stated above must be defined in the ABAP report prog as follows:
    FORM <form> TABLES IN_TAB STRUCTURE ITCSY
    OUT_TAB STRUCTURE ITCSY.
    ENDFORM.
    The values of the SAPscript symbols passed with /: USING... are now stored in the internal table IN_TAB . Note that the system passes the values as character string to the subroutine, since the field Feld VALUE in structure ITCSY has the domain TDSYMVALUE (CHAR 80). See the example below on how to access the variables.
    The internal table OUT_TAB contains names and values of the CHANGING parameters in the PERFORM statement. These parameters are local text symbols, that is, character fields. See the example below on how to return the variables within the subroutine.
    From within a SAPscript form, a subroutine GET_BARCODE in the ABAP program QCJPERFO is called. Then the simple barcode contained there (‘First page’, ‘Next page’, ‘Last page’) is printed as local variable symbol.
    Definition in the SAPscript form:
    /: PERFORM GET_BARCODE IN PROGRAM QCJPERFO
    /: USING &PAGE&
    /: USING &NEXTPAGE&
    /: CHANGING &BARCODE&
    /: ENDPERFORM
    / &BARCODE&
    Coding of the calling ABAP program:
    REPORT QCJPERFO.
    FORM GET_BARCODE TABLES IN_PAR STUCTURE ITCSY
    OUT_PAR STRUCTURE ITCSY.
    DATA: PAGNUM LIKE SY-TABIX, "page number
    NEXTPAGE LIKE SY-TABIX. "number of next page
    READ TABLE IN_PAR WITH KEY ‘PAGE’.
    CHECK SY-SUBRC = 0.
    PAGNUM = IN_PAR-VALUE.
    READ TABLE IN_PAR WITH KEY ‘NEXTPAGE’.
    CHECK SY-SUBRC = 0.
    NEXTPAGE = IN_PAR-VALUE.
    READ TABLE OUT_PAR WITH KEY ‘BARCODE’.
    CHECK SY-SUBRC = 0.
    IF PAGNUM = 1.
    OUT_PAR-VALUE = ‘|’. "First page
    ELSE.
    OUT_PAR-VALUE = ‘||’. "Next page
    ENDIF.
    IF NEXTPAGE = 0.
    OUT_PAR-VALUE+2 = ‘L’. "Flag: last page
    ENDIF.
    MODIFY OUT_PAR INDEX SY-TABIX.
    ENDFORM.
    Regards,
    Vara

  • Function module for calculating sigma balance

    Is there  any function module available in SAP for calculating sigma balance.
    Thanks
    Gaurav

    hi
    ABAP_DOCU_DOWNLOAD     Download ABAP documentation in HTML format.
    APPL_LOG_DELETE     With this function module you delete logs in the database according to specified selection conditions
    APPL_LOG_DISPLAY     With this function module you can analyze logs in the database.
    APPL_LOG_DISPLAY_INTERN     With this function module you can analyze logs in local memory, e.g. when you have only collected log records at runtime and do not want to write to the database.
    APPL_LOG_INIT     This function module checks whether the specified object or sub-object exists and deletes all existing associated data in local memory.
    APPL_LOG_READ_DB     With this function module you read the log data in the database for an object or sub-object according to specified selection conditions.
    APPL_LOG_READ_INTERN     With this function module you read all log data whose log class has at least the specified value, from local memory, for the specified object or sub-object.
    APPL_LOG_SET_OBJECT     With this function module, you create a new object or sub-object for writing in local memory. With a flag you can control whether the APPL_LOG_WRITE_... messages are written in local memory or are output on the screen.
    APPL_LOG_WRITE_DB     With this function module you write all data for the specified object or sub-object in local memory to the database. If the log for the object or sub-object in question is new, the log number is returned to the calling program.
    APPL_LOG_WRITE_HEADER     With this function module, you write the log header data in local memory.
    APPL_LOG_WRITE_LOG_PARAMETERS     With this function module, you write the name of the log parameters and the associated values for the specified object or sub-object in local memory. If this function module is called repeatedly for the same object or sub-object, the existing parameters are updated accordingly. If you do not specify an object or sub-object with the call, the most recently used is assumed.
    APPL_LOG_WRITE_MESSAGE_PARAMS     With this function module you write a single message, with parameters, in local memory. Otherwise the function module works like APPL_LOG_WRITE_SINGLE_MESSAGE.
    APPL_LOG_WRITE_MESSAGES     With this function module you write one or more messages, without parameters, in local memory.
    APPL_LOG_WRITE_SINGLE_MESSAGE     With this function module you write a single message, without parameters, in local memory. If no header entry has yet been written for the object or sub-object, it is created. If you do not specify an object or sub-object with the call, the most recently used is assumed.
    ARFC_GET_TID     will return the IP address of the terminal in hex.
    BAL_CNTL_CREATE     Create Control for log display
    BAL_CNTL_FREE     Release Control
    BAL_CNTL_REFRESH     Put new data in log display
    BAL_DB_DELETE     Delete logs from the database
    BAL_DB_DEQUEUE     Unlock log
    BAL_DB_ENQUEUE     Lock log
    BAL_DB_LOAD     Load logs from the database
    BAL_DB_LOAD     Load log(s)
    BAL_DB_SAVE     Save logs in the database
    BAL_DB_SAVE     Save log(s)
    BAL_DB_SAVE_PREPARE     Prepare save
    BAL_DB_SEARCH     Find logs in the database
    BAL_DSP_LOG_DISPLAY     Display messages in memory
    BAL_DSP_LOG_DISPLAY     Display Log
    BAL_DSP_LOG_PARAMETERS     Either output extended long text or call a callback routine (based on the data in BAL_S_LOG-PARAMS)
    BAL_DSP_LOG_TECHNICAL_DATA     Output all log header data
    BAL_DSP_MSG_LONGTEXT     Display message long text
    BAL_DSP_MSG_PARAMETERS     Either output extended long text or call a callback routine (based on the data in BAL_S_MSG-PARAMS)
    BAL_DSP_MSG_TECHNICAL_DATA     Output technical data of a message such as work area, error number, etc.
    BAL_DSP_OUTPUT_FREE     End output
    BAL_DSP_OUTPUT_INIT     Initialize output
    BAL_DSP_OUTPUT_SET_DATA     Set dataset to be displayed
    BAL_DSP_PROFILE_DETLEVEL_GET     Message hierarchy in DETLEVEL
    BAL_DSP_PROFILE_NO_TREE_GET     Display without tree (fullscreen)
    BAL_DSP_PROFILE_POPUP_GET     Display without tree (popup)
    BAL_DSP_PROFILE_SINGLE_LOG_GET     Standard profile (SLG1) for one log
    BAL_DSP_PROFILE_STANDARD_GET     Standard profile (SLG1) for a lot of logs
    BAL_GLB_AUTHORIZATION_GET     Assign authorization
    BAL_GLB_AUTHORIZATION_RESET     Reset authorization
    BAL_GLB_CONFIG_GET     Read configuration
    BAL_GLB_CONFIG_SET     Set configuration
    BAL_GLB_MEMORY_EXPORT     Put function group memory in ABAP-MEMORY
    BAL_GLB_MEMORY_IMPORT     Get function group memory from ABAP-MEMORY
    BAL_GLB_MEMORY_REFRESH     (Partially) reset global memory
    BAL_GLB_MEMORY_REFRESH     (Partially) initialize memory
    BAL_GLB_MSG_CURRENT_HANDLE_GET     Get current message handle
    BAL_GLB_MSG_DEFAULTS_GET     Get message defaults
    BAL_GLB_SEARCH_LOG     Find logs in memory
    BAL_GLB_SEARCH_MSG     Find messages in memory
    BAL_LOG_CREATE     Create log with header data
    BAL_LOG_CREATE     Create log with header data
    BAL_LOG_DELETE     Delete log (from database also at Save)
    BAL_LOG_EXIST     Check existence of a log in memory
    BAL_LOG_HDR_CHANGE     Change log header
    BAL_LOG_HDR_CHECK     Check log header data for consistency
    BAL_LOG_HDR_READ     Read log header and other data
    BAL_LOG_MSG_ADD     Put message in log
    BAL_LOG_MSG_ADD     Put message in log
    BAL_LOG_MSG_CHANGE     Change message
    BAL_LOG_MSG_CHANGE     Change message
    BAL_LOG_MSG_CHECK     Check message data for consistency
    BAL_LOG_MSG_CUMULATE     Add message cumulated
    BAL_LOG_MSG_DELETE     Delete message
    BAL_LOG_MSG_DELETE     Delete message
    BAL_LOG_MSG_EXIST     Check existence of a message in memory
    BAL_LOG_MSG_READ     Read message and other data
    BAL_LOG_MSG_REPLACE     Replace last message
    BAL_LOG_REFRESH     Delete log from memory
    BAL_LOG_REFRESH     Delete log from memory
    BAL_MSG_DISPLAY_ABAP     Output message as ABAP-MESSAGE
    BAL_OBJECT_SELECT     Read Application Log objects table record
    BAL_OBJECT_SUBOBJECT     Check whether object and subobject exist and the combination is allowed
    BAL_SUBOBJECT_SELECT     Read subobject table record
    BP_EVENT_RAISE     Trigger an event from ABAP/4 program
    BP_JOBLOG_READ     Fetch job log executions
    CHANGEDOCUMENT_READ_HEADERS     Get the change document header for a sales document, and put the results in an internal table.
    Example:
          CALL FUNCTION 'CHANGEDOCUMENT_READ_HEADERS'
               EXPORTING
                    objectclass = 'EINKBELEG'
                    objectid    = l_objectid
                    username    = space
               TABLES
                    i_cdhdr     = lt_cdhdr.
          LOOP AT lt_cdhdr WHERE udate IN s_aedat.
            CALL FUNCTION 'CHANGEDOCUMENT_READ_POSITIONS'
                 EXPORTING
                      changenumber = lt_cdhdr-changenr
                 TABLES
                      editpos      = lt_editpos.
            LOOP AT lt_editpos WHERE fname = 'LOEKZ'
                               AND   f_new = 'L'.
              p_desc = text-r01. " Cancel Contract
            ENDLOOP.
          ENDLOOP.
    CHANGEDOCUMENT_READ_POSITIONS     Get the details of a change document, and store them in an internal table. This will tell you whether a field was changed, deleted, or updated.
    Example:
          CALL FUNCTION 'CHANGEDOCUMENT_READ_HEADERS'
               EXPORTING
                    objectclass = 'EINKBELEG'
                    objectid    = l_objectid
                    username    = space
               TABLES
                    i_cdhdr     = lt_cdhdr.
          LOOP AT lt_cdhdr WHERE udate IN s_aedat.
            CALL FUNCTION 'CHANGEDOCUMENT_READ_POSITIONS'
                 EXPORTING
                      changenumber = lt_cdhdr-changenr
                 TABLES
                      editpos      = lt_editpos.
            LOOP AT lt_editpos WHERE fname = 'LOEKZ'
                               AND   f_new = 'L'.
              p_desc = text-r01. " Cancel Contract
            ENDLOOP.
          ENDLOOP.
    CLAF_CLASSIFICATION_OF_OBJECTS     Return all of the characteristics for a material
    CLOI_PUT_SIGN_IN_FRONT     Move the negative sign from the left hand side of a number, to the right hand side of the number. Note that The result will be left justified (like all character fields), not right justifed as numbers normally are.
    CLPB_EXPORT     Export a text table to the clipboard (on presentation server)
    CLPB_IMPORT     Import a Text Table from the Clipboard (on presentation server)
    COMMIT_TEXT     To load long text into SAP
    CONVERSION_EXIT_ALPHA_INPUT     converts any number into a string fill with zeroes, with the number at the extreme right
    Example:
    input  = 123
    output = 0000000000000...000000000000123
    CONVERSION_EXIT_ALPHA_OUTPUT     converts any number with zeroes right into a simple integer
    Example:
    input   = 00000000000123
    output  = 123
    CONVERT_ABAPSPOOLJOB_2_PDF     convert abap spool output to PDF
    CONVERT_OTF     Convert SAP documents (SAPScript) to other types.
    Example:
    CALL FUNCTION "CONVERT_OTF"
           EXPORTING    FORMAT                = "PDF"
           IMPORTING    BIN_FILESIZE          = FILE_LEN
           TABLES       OTF                   = OTFDATA
                        LINES                 = PDFDATA
           EXCEPTIONS   ERR_MAX_LINEWIDTH     = 1                  
                        ERR_FORMAT            = 2
                        ERR_CONV_NOT_POSSIBLE = 3
                        OTHERS                = 4.
    CONVERT_OTFSPOOLJOB_2_PDF     converts a OTF spool to PDF (i.e. Sapscript document)
    CONVERT_TO_FOREIGN_CURRENCY     Convert local currency to foreign currency.
    CONVERT_TO_LOCAL_CURRENCY     Convert from foreign currency to local currency
    DATE_CHECK_PLAUSIBILITY     Check to see if a date is in a valid format for SAP. Works well when validating dates being passed in from other systems.
    DATE_COMPUTE_DAY     Returns a number indicating what day of the week the date falls on. Monday is returned as a 1, Tuesday as 2, etc.
    DATE_GET_WEEK     will return the week that a date is in.
    DATE_IN_FUTURE     Calculate a date N days in the future.
    DAY_ATTRIBUTES_GET
    Return useful information about a day. Will tell you the day of the week as a word (Tuesday), the day of the week (2 would be Tuedsay), whether the day is a holiday, and more.(provided by Francois Henrotte)
    DOWNLOAD     download a file to the presentation server (PC)
    DYNP_VALUES_READ     Read the values from a dynpro. This function can be used to read the values from a report's selection screen too (Another example).
    DYNP_VALUES_UPDATE     Similar to DYNP_VALUES_READ, this function will allow the updating of fields on a dynpro. Very useful when you want to change a field based on the value entered for another field.
    ENQUE_SLEEP     Wait a specified period of time before continuing processing.
    ENQUEUE_ESFUNCTION     Lock an abap program so that it cannot be executed.
    Example:
    Set the parameters as follows:
      RELID = 'ZZ'
      SRTF2 = 0
      SRTF = (your report name)
    Please note that you should not use SY-REPID to pass your report name to the function. The value of SY-REPID will change as it is being passed to the function module, and will no longer hold the value of the calling report.
    EPS_GET_DIRECTORY_LISTING     return a list of filenames from a local or network drive
    EPS_GET_FILE_ATTRIBUTES     Pass in a filename and a path, and will return attributes for the file
    F4_DATE     displays a calendar in a popup window and allows user to choose a date, or it can be displayed read only.
    F4_IF_FIELD_VALUE_REQUEST     Use values from a DDIC table to provide a list of possible values. TABNAME and FIELDNAME are required fields, and when MULTIPLE_CHOICE is selected, more than one value can be returned.
    F4IF_INT_TABLE_VALUE_REQUEST     F4 help that returns the values selected in an internal table. Very handy when programming your very own F4 help for a field.
    Example:
    data:
        begin of t_values occurs 2,
          value like kna1-begru,
        end of t_values,
        t_return like ddshretval occurs 0 with header line.
      t_values = 'PAR*'.
      append t_values.
      t_values = 'UGG'.
      append t_values.
      call function 'F4IF_INT_TABLE_VALUE_REQUEST'
           exporting
                retfield        = 'BEGRU'
                value_org       = 'S'
           tables
                value_tab       = t_values
                return_tab      = t_return
           exceptions
                parameter_error = 1
                no_values_found = 2
                others          = 3.
      if sy-subrc = 0.
        read table t_return index 1.
        o_begru-low = t_return-fieldval.
        if o_begru-low = 'PAR*'.
          o_begru-option = 'CP'.
        else.
          o_begru-option = 'EQ'.
        endif.
        o_begru-sign = 'I'.
        append o_begru to s_begru.
      else.
        o_begru = i_begru.
      endif.
    F4IF_SHLP_EXIT_EXAMPLE     documents the different reasons to use a search help exit, and shows how it is done.
    F4IP_INT_TABLE_VALUE_REQUEST     This function does not exist in 4.6 and above. Use F4IF_INT_TABLE_VALUE_REQUEST instead.
    FILENAME_GET     popup to get a filename from a user, returns blank filename if user selects cancel
    FORMAT_MESSAGE     Takes a message id and number, and puts it into a variable. Works better than WRITE_MESSAGE, since some messages use $ as a place holder, and WRITE_MESSAGE does not accommadate that, it only replaces the ampersands (&) in the message.
    FTP_COMMAND     Execute a command on the FTP server
    FTP_CONNECT     Open a connection (and log in) to an FTP server
    FTP_DISCONNECT     Close the connection (and log off) the FTP server
    FU CSAP_MAT_BOM_READ     You can use this function module to display simple material BOMs. You cannot display BOM groups (for example, all variants of a variant BOM). as in transaction CS03. Current restrictions: You cannot display long texts. You cannot display sub-items. You cannot display classification data of BOM items for batches. You can only display one alternative or variant. You cannot enter an alternative for module CSAP_MAT_BOM_READ, so you always see alternative 01. The following example came from a posting on the SAP-R3-L mailing list.
    Example:
    data: begin of tstk2 occurs 0.
              include structure stko_api02.
    data: end of tstk2.
    data: begin of tstp2 occurs 0.
              include structure stpo_api02.
    data: end of tstp2.
    data: begin of tdep_data occurs 0.
             include structure csdep_data.
    data: end of tdep_data.
    data: begin of tdep_descr occurs 0.
             include structure csdep_descr.
    data: end of tdep_descr.
    data: begin of tdep_source occurs 0.
             include structure csdep_source.
    data: end of tdep_source.
    data: begin of tdep_order occurs 0.
             include structure csdep_order.
    data: end of tdep_order.
    data: begin of tdep_doc occurs 0.
             include structure csdep_doc.
    data: end of tdep_doc.
    data: flg_warning like capiflag-flwarning.
       call function 'CSAP_MAT_BOM_READ'
            exporting
                 material   = 'MAT100'
                 plant      = '0001'
                 bom_usage  = '1'
                 valid_from = '20.12.1996'
               valid_to
            importing
                 fl_warning = flg_warning
            tables
                 t_stko       = tstk2
                 t_stpo       = tstp2
                 t_dep_data   = tdep_data
                 t_dep_descr  = tdep_descr
                 t_dep_source = tdep_source
                 t_dep_order  = tdep_order
                 t_dep_doc    = tdep_doc
            exceptions
                 error      = 1.
    Function Group GRAP is now obsolete.     SAP recommends using functions in function group SFES instead. Below is an overview of the changes.
    G_SET_GET_ALL_VALUES     Fetch values from a set.
    GET_CURRENT_YEAR     Get the current fiscal year.
    Example:
    CALL FUNCTION 'GET_CURRENT_YEAR'
      EXPORTING
        BUKRS         = '1000'     " Company Code
        DATE          = SY-DATUM   " Date to find fiscal year for
      IMPORTING
        CURRM         = w_currm    " Current Fiscal Month
        CURRY         = w_curry    " Current Fiscal Year
        PREVM         = w_prevm    " Previous Fiscal Month
        PREVY         = w_prevy.   " Previous Fiscal Year
    GET_GLOBAL_SYMBOLS     Returns a list of all tables, select options, texts, etc for a program. Even includes the text definitions for the selection screen
    GET_INCLUDETAB     Returns a list of all INCLUDES in a program
    GET_JOB_RUNTIME_INFO
    Get the current job number from a program. Also returns other useful info about the current job.
    GUI_CREATE_DIRECTORY     Create a directory on the presentation server
    GUI_DELETE_FILE     Replaces WS_FILE_DELETE. Delete a file on the presentation server
    GUI_DOWNLOAD     Replaces WS_DOWNLOAD. Download table from the app server to presentation server
    GUI_EXEC     Replaces WS_EXECUTE. Start a File or Program Asynchronously with WinExec
    GUI_GET_DESKTOP_INFO     Replaces WS_QUERY. Delivers Information About the Desktop (client)
    GUI_REMOVE_DIRECTORY     Delete a directory on the presentation server
    GUI_RUN     Start a File or Program Asynchronously with ShellExecute
    GUI_UPLOAD     Replaces WS_UPLOAD. Upoad file from presentation server to the app server
    HELP_START     Display help for a field. Useful for doing AT SELECTION SCREEN ON VALUE REQUEST for those fields that do not provide F4 help at the DDIC level.
    HELP_VALUES_GET_WITH_TABLE     Show a list of possible values for F4 popup help on selection screens. This function module pops up a screen that is just like all the other F4 helps, so it looks like the rest of the SAP system. Very useful for providing dropdowns on fields that do not have them predefined.
    Example:
    tables: t001w.
    DATA: lc_werks      LIKE t001w-werks,
          ltab_fields LIKE help_value OCCURS 0 with header line,
          BEGIN OF ltab_values OCCURS 0,
            feld(40) TYPE c,
          END OF ltab_values.
    *-- Set up fields to retrieve data
      ltab_fields-tabname    = 'T001W'.
      ltab_fields-fieldname  = 'WERKS'.
      ltab_fields-selectflag = 'X'.
      APPEND ltab_fields.
      ltab_fields-tabname    = 'T001W'.
      ltab_fields-fieldname  = 'NAME1'.
      ltab_fields-selectflag = space.
      APPEND ltab_fields.
    *-- Fill values
      select * from t001w.
        ltab_values-feld = t001w-werks.
        append ltab_values.
        ltab_values-feld = t001w-name1.
        append ltab_values.
      endselect.
    CALL FUNCTION 'HELP_VALUES_GET_WITH_TABLE'
         EXPORTING
              fieldname                 = 'WERKS'
              tabname                   = 'T001W'
              title_in_values_list      = 'Select a value'
         IMPORTING
              select_value              = lc_werks
         TABLES
              fields                    = ltab_fields
              valuetab                  = ltab_values
         EXCEPTIONS
              field_not_in_ddic         = 01
              more_then_one_selectfield = 02
              no_selectfield            = 03.
    HOLIDAY_CHECK_AND_GET_INFO     Useful for determining whether or not a date is a holiday. Give the function a date, and a holiday calendar, and you can determine if the date is a holiday by checking the parameter HOLIDAY_FOUND.
    Example:
    data: ld_date                 like scal-datum  default sy-datum,
          lc_holiday_cal_id       like scal-hcalid default 'CA',
          ltab_holiday_attributes like thol occurs 0 with header line,
          lc_holiday_found        like scal-indicator.
    CALL FUNCTION 'HOLIDAY_CHECK_AND_GET_INFO'
      EXPORTING
        date                               = ld_date
        holiday_calendar_id                = lc_holiday_cal_id
        WITH_HOLIDAY_ATTRIBUTES            = 'X'
      IMPORTING
        HOLIDAY_FOUND                      = lc_holiday_found
      tables
        holiday_attributes                 = ltab_holiday_attributes
      EXCEPTIONS
        CALENDAR_BUFFER_NOT_LOADABLE       = 1
        DATE_AFTER_RANGE                   = 2
        DATE_BEFORE_RANGE                  = 3
        DATE_INVALID                       = 4
        HOLIDAY_CALENDAR_ID_MISSING        = 5
        HOLIDAY_CALENDAR_NOT_FOUND         = 6
        OTHERS                             = 7.
    if sy-subrc = 0 and
       lc_holiday_found = 'X'.
      write: / ld_date, 'is a holiday'.
    else.
      write: / ld_date, 'is not a holiday, or there was an error calling the function'.
    endif.
    HOLIDAY_GET     Provides a table of all the holidays based upon a Factory Calendar &/ Holiday Calendar.
    HR_DISPLAY_BASIC_LIST     is an HR function, but can be used for any data. You pass it data, and column headers, and it provides a table control with the ability to manipulate the data, and send it to Word or Excel. Also see the additional documentation here.
    HR_GET_LEAVE_DATA     Get all leave information (includes leave entitlement, used holidays/paid out holidays)
    HR_IE_NUM_PRSI_WEEKS     Return the number of weeks between two dates.
    HR_PAYROLL_PERIODS_GET
    Get the payroll period for a particular date. (provided by Francois Henrotte)
    Example:
      DATA: IT_T549Q TYPE T549Q OCCURS 0 WITH HEADER LINE,
            IT_ZL TYPE PC2BF OCCURS 0 WITH HEADER LINE.
      W_BEGDA = '20010101'.
      W_PERNR = '00000001'.
      CALL FUNCTION 'HR_PAYROLL_PERIODS_GET'
           EXPORTING
                get_begda       = w_begda
           TABLES
                get_periods     = it_t549q
           EXCEPTIONS
                no_period_found = 1
                no_valid_permo  = 2.
      CHECK sy-subrc = 0.
      CALL FUNCTION 'HR_TIME_RESULTS_GET'
           EXPORTING
                get_pernr             = w_pernr
                get_pabrj             = it_t549q-pabrj
                get_pabrp             = it_t549q-pabrp
           TABLES
                get_zl                = it_zl
           EXCEPTIONS
                no_period_specified   = 1
                wrong_cluster_version = 2
                no_read_authority     = 3
                cluster_archived      = 4
                technical_error       = 5.
    NOTE: it_zl-iftyp = 'A'   absence
          it_zl-iftyp = 'S'   at work
    HR_TIME_RESULTS_GET
    Get the time results for a payroll period. (provided by Francois Henrotte)
    Example:
      DATA: IT_T549Q TYPE T549Q OCCURS 0 WITH HEADER LINE,
            IT_ZL TYPE PC2BF OCCURS 0 WITH HEADER LINE.
      W_BEGDA = '20010101'.
      W_PERNR = '00000001'.
      CALL FUNCTION 'HR_PAYROLL_PERIODS_GET'
           EXPORTING
                get_begda       = w_begda
           TABLES
                get_periods     = it_t549q
           EXCEPTIONS
                no_period_found = 1
                no_valid_permo  = 2.
      CHECK sy-subrc = 0.
      CALL FUNCTION 'HR_TIME_RESULTS_GET'
           EXPORTING
                get_pernr             = w_pernr
                get_pabrj             = it_t549q-pabrj
                get_pabrp             = it_t549q-pabrp
           TABLES
                get_zl                = it_zl
           EXCEPTIONS
                no_period_specified   = 1
                wrong_cluster_version = 2
                no_read_authority     = 3
                cluster_archived      = 4
                technical_error       = 5.
    NOTE: it_zl-iftyp = 'A'   absence
          it_zl-iftyp = 'S'   at work
    INIT_TEXT     To load long text into SAP
    K_WERKS_OF_BUKRS_FIND     Return a list of all plants for a given company code.
    LIST_FROM_MEMORY     Retrieves the output of a report from memory when the report was executed using SUBMIT... EXPORTING LIST TO MEMORY. See also WRITE_LIST.
    LIST_TO_ASCII     convert an ABAP report (displayed on screen) from OTF to ASCII format
    MBEW_EXTEND
    Get the stock position for the previous month. This displays the same info that you see in MM03.
    MONTH_NAMES_GET     It returns all the month and names in repective language.
    MONTH_PLUS_DETERMINE     Add or subtract months from a date. To subtract a month, enter a negative value for the 'months' parameter.
    Example:
    data: new_date type d.
    CALL FUNCTION 'MONTH_PLUS_DETERMINE'
      EXPORTING
        months        = -5       " Negative to subtract from old date, positive to add
        olddate       = sy-datum
    IMPORTING
       NEWDATE       = new_date.
    write: / new_date.
    MS_EXCEL_OLE_STANDARD_OLE     will build a file, and automatically start Excel
    OTF_CONVERT     wraps several other function modules. Will convert OTF to ASCII or PDF
    POPUP_TO_CONFIRM_LOSS_OF_DATA     Create a dialog box in which you make a question whether the user wishes to perform a processing step with loss of data.
    POPUP_TO_CONFIRM_STEP     Create a dialog box in which you make a question whether the user wishes to perform the step.
    POPUP_TO_CONFIRM_WITH_MESSAGE     Create a dialog box in which you inform the user about a specific decision point during an action.
    POPUP_TO_CONFIRM_WITH_VALUE     Create a dialog box in which you make a question whether the user wishes to perform a processing step with a particular object.
    POPUP_TO_DECIDE     Provide user with several choices as radio buttons
    POPUP_TO_DECIDE_WITH_MESSAGE     Create a dialog box in which you inform the user about a specific decision point via a diagnosis text.
    POPUP_TO_DISPLAY_TEXT     Create a dialog box in which you display a two line message
    POPUP_TO_SELECT_MONTH     Popup to choose a month
    POPUP_WITH_TABLE_DISPLAY     Provide a display of a table for user to select one, with the value of the table line returned when selected.
    PRICING     Return pricing conditions in an internal table. Use structure TCOMK for parameter COMM_HEAD_1, and structure TCOMP for parameter COMM_ITEM_1, and set CALCULATION_TYPE to B. The pricing conditions will be returned in XOMV. You must fill TCOMP, and TCOMK with the appropriate values before callling the function in order for it to work.
    PROFILE_GET     Read an Entry in an INI File on the frontend
    PROFILE_SET     Write an Entry in an INI File on the frontend
    READ_TEXT     To load long text into SAP
    REGISTRY_GET     Read an Entry from the Registry
    REGISTRY_SET     Set an entry in the Registry
    RFC_ABAP_INSTALL_AND_RUN     Runs an ABAP program that is stored in the table PROGRAM when the MODE = 'F'. Table WRITES contains the ouput of the program. Allows you to run a program without having the source code in the target system.
    RH_GET_ACTIVE_WF_PLVAR     Return the active HR Plan
    RH_GET_DATE_DAYNAME     return the day based on the date provied
    RH_START_EXCEL_WITH_DATA     starts Excel with the contents of an internal table. This function finds Excel in the desktop registry. It also uses a local PC working directory to save the file (that's what the 'W' value for data path flag does). Very transparent to user!
    RH_STRUC_GET     Returns all related org info
    RHP0_POPUP_F4_SEARK
    is a matchcode for any type of HR Planning object, including the possibility to fill the field that you want
    Example:
    Examples: search for any organizational structure
               F4 = 'X'
               PLVAR = '01'
               OTYPE = 'O '
              search for any persons
               F4 = 'X'
               PLVAR = '01'
               OTYPE = 'P '
               MULTI_SELECT = 'X' to allow multiple selection
               EASY = 'X' for user-dependent matchcode
    Unfortunately, the use of table BASE_OBJIDS is disabled, so you can't specify
    a root for the hierarchy you display
    RKD_WORD_WRAP     Convert a long string or phrase into several lines.
    RP_CALC_DATE_IN_INTERVAL     Add/subtract years/months/days from a date
    RP_LAST_DAY_OF_MONTHS     Determine last day of month
    RPY_DYNPRO_READ     Read dynpro, including screen flow
    RPY_TRANSACTION_READ     Given a transaction, return the program and screen or given a program and screen, return the transactions that use the program and screen.
    RS_COVERPAGE_SELECTIONS     Returns an internal table that contains a formatted list of all the selection parameters entered for a report. Table is ready to print out.
    RS_REFRESH_FROM_SELECTOPTIONS     Get the current contents of selection screen
    RS_SEND_MAIL_FOR_SPOOLLIST     Send message from ABAP/4 program to SAPoffice.
    RS_VARIANT_CONTENTS     Returns the contents of the specified variant in a table.
    RSPO_DOWNLOAD_SPOOLJOB     Download the spool from a program to a file. Requires spool number.
    RSPO_RETURN_ABAP_SPOOLJOB     Fetch printer spool according to the spool number informed.
    RZL_READ_DIR     If the server name is left blank, it reads a directory from local presentation server, otherwise it reads the directory of the remote server
    RZL_READ_DIR_LOCAL     Read a directory on the Application Server
    RZL_READ_FILE     Read a file from the presentation server if no server name is given, or read file from remote server. Very useful to avoid authority checks that occur doing an OPEN DATASET. This function using a SAP C program to read the data.
    RZL_SLEEP     Hang the current application from 1 to 5 seconds.
    RZL_SUBMIT     Submit a remote report.
    RZL_WRITE_FILE_LOCAL     Saves table to the presentation server (not PC). Does not use OPEN DATASET, so it does not suffer from authority checks!
    SAP_CONVERT_TO_XLS_FORMAT     Convert data to Microsoft Excel format.
    SAPGUI_PROGRESS_INDICATOR     Display a progress bar on the SAP GUI, and give the user some idea of what is happening
    SAVE_TEXT     To load long text into SAP
    SCROLLING_IN_TABLE     If you are coding a module pool and using a table control, you can use this function SCROLLING_IN_TABLE to handle any scrolling. (provided by Paul Kjaer)
    SD_DATETIME_DIFFERENCE     Give the difference in Days and Time for 2 dates
    SO_NEW_DOCUMENT_ATT_SEND_API1     Send a document as part of an email. The documentation is better than normal for this function, so please read it.
    SO_SPLIT_FILE_AND_PATH     Split a fully pathed filename into a filename and a path.
    SO_SPOOL_READ     Fetch printer spool according to the spool number informed. See also RSPO_RETURN_ABAP_SPOOLJOB
    SO_WIND_SPOOL_LIST     Browse printer spool numbers according to user informed.
    SWD_HELP_F4_ORG_OBJECTS
    HR Matchcode tailored for organizational units. Includes a button so that you can browse the hierarchy too.
    SX_OBJECT_CONVERT_OTF_PDF     Conversion From OTF to PDF (SAPScript conversion)
    SX_OBJECT_CONVERT_OTF_PRT     Conversion From OTF to Printer Format (SAPScript conversion)
    SX_OBJECT_CONVERT_OTF_RAW     Conversion From OTF to ASCII (SAPScript conversion)
    SXPG_CALL_SYSTEM     you can check the user's authorization for the specified command and run the command. The command runs on the host system on which the function module is executed. The function module is RFC capable. It can therefore be run on the host system at which a user happens to be active or on another designated host system at which an R/3 server is active.
    SXPG_COMMAND_CHECK     Check whether the user is authorized to execute the specified command on the target host system with the specified arguments.
    SXPG_COMMAND_DEFINITION_GET     Read the definition of a single external OS command from the R/3 System's database.
    SXPG_COMMAND_EXECUTE     Check a user's authorization to use a command, as in SXPG_COMMAND_CHECK. If the authorization check is successful, then execute the command on the target host system.
    SXPG_COMMAND_LIST_GET     Select a list of external OS command definitions.
    TERMINAL_ID_GET     Return the terminal id
    TH_DELETE_USER     Logoff a user. Similar results to using SM04.
    TH_ENVIRONMENT     Get the UNIX environment
    TH_POPUP     Display a popup system message on a specific users screen.
    TH_REMOTE_TRANSACTION     Run a transaction on a remote server. Optionally provide BDC data to be used in the transaction
    TH_USER_INFO     Give information about the current user (sessions, workstation logged in from, etc)
    TH_USER_LIST     Show which users are logged into an app server
    TMP_GUI_DIRECTORY_LIST_FILES     Retrieve all of the files and subdirectories on the Presentation Server (PC) for a given directory.
    When a value other than * or . is used for the filter, you will not get any directories, unless they match your wildcard filter. For example, if you entered *.png, then only files and directories that end in png will be returned by the function.
    Example:
    data:  lc_directory         like bdschko16-target_dir value 'C:\TEMP\',
           lc_filter(20)        type c default '.'.
           li_file_count        type i,
           li_dir_count         type i,
           ltab_dir_table       like sdokpath occurs 0 with header line,
           ltab_file_file_table like sdokpath occurs 0 with header line.
    call function 'TMP_GUI_DIRECTORY_LIST_FILES'
      exporting
        directory        = lc_directory
        filter           = lc_filter  importing
        file_count       = li_file_count
        dir_count        = li_dir_count
      tables
        file_table       = ltab_file_table
        dir_table        = ltab_dir_table
      exceptions
        cntl_error       = 1
        others           = 2.
    UNIT_CONVERSION_SIMPLE     convert weights from one UOM to another.
    UPLOAD     upload a file to the presentation server (PC)
    UPLOAD_FILES     Will load one or more files from app or presentation server
    WEEK_GET_FIRST_DAY     For a given week (YYYYMM format), this function returns the date of the Monday of that week.
    WRITE_LIST     Useful for writing out the list contents that result from the function LIST_FROM_MEMORY.
    WS_DOWNLOAD     Save Internal Table as File on the Presentation Server
    WS_EXCEL     Start EXCEL on the PC
    WS_EXECUTE     execute a program on a windows PC
    WS_FILE_DELETE     Delete File at the Frontend
    WS_FILENAME_GET     Call File Selector
    WS_MSG     Create a dialog box in which you display an one line message
    WS_UPLOAD     Load Files from the Presentation Server to Internal ABAP Tables
    WS_VOLUME_GET     Get the label from a frontend device.
    WWW_LIST_TO_HTML     After running a report, call this function to convert the list output to HTML.
    hope it will help you.
    Regards,
    Sreelatha gullapalli

  • Columns in SApScripts

    Hi All,
    Please tell me how can i put columns & rows in SAPScripts?
    Is there any way where i can hide the columns wherever they are not needed?
    Please answer my question asap.
    Thanks & Regards,
    Bhavika

    Hi
    By drawing the peoper boxes you can put the rows and Colum,ns in a table like structure
    see the commands for drawing them
    SAPScripts
    POSITION WINDOW
    SIZE WIDTH '160' MM HEIGHT '140' MM
    BOX FRAME 10 TW
    Box
    BOX HEIGHT '11' MM WIDTH '160' MM FRAME 10 TW INTENSITY 35
    linessssssss
    BOX XPOS '20' MM WIDTH 0 TW HEIGHT '140' MM FRAME 10 TW
    BOX XPOS '45' MM WIDTH 0 TW HEIGHT '140' MM FRAME 10 TW
    BOX XPOS '80' MM WIDTH 0 TW HEIGHT '140' MM FRAME 10 TW
    BOX XPOS '120' MM WIDTH 0 TW HEIGHT '140' MM FRAME 10 TW
    Boxes, Lines, Shading: BOX, POSITION, SIZE
    Use the BOX, POSITION, and SIZE commands for drawing boxes, lines, and shading to print particular windows within a form or passages of text within a window in a frame or with shading.
    The SAP printer drivers that are based on page-oriented printers (the HP LaserJet driver HPL2, the Postscript driver POST, the Kyocera Prescribe driver PRES) employ these commands when printing. Line printers and page-oriented printers not supported in the standard ignore these commands. You can view the resulting printer output in the SAPscript print preview.
    Syntax:
    /: BOX [XPOS] [YPOS] [WIDTH] [HEIGHT] [FRAME] [INTENSITY]
    /: POSITION [XORIGIN] [YORIGIN] [WINDOW] [PAGE]
    /: SIZE [WIDTH] [HEIGHT] [WINDOW] [PAGE]
    BOX Command
    Syntax
    /: BOX [XPOS] [YPOS] [WIDTH] [HEIGHT] [FRAME] [INTENSITY]
    Effect: draws a box of the specified size at the specified position.
    Parameters: For each of XPOS, YPOS, WIDTH, HEIGHT, and FRAME, you must specify both a measurement and a unit of measurement. Specify the INTENSITY parameter as a percentage between 0 and 100.
    XPOS, YPOS
    Upper left corner of the box, relative to the values of the POSITION command.
    Default: Values specified in the POSITION command.
    The following calculation is performed internally to determine the absolute output position of a box on the page:
    X(abs) = XORIGIN + XPOS
    Y(abs) = YORIGIN + YPOS
    WIDTH
    Width of the box. Default: WIDTH value of the SIZE command.
    HEIGHT
    Height of the box. Default: HEIGHT value of the SIZE command.
    FRAME
    Thickness of frame.
    Default: 0 (no frame).
    INTENSITY
    Grayscale of box contents as %.
    Default: 100 (full black)
    Measurements: You must specify decimal numbers as literal values (like ABAP numeric constants) by enclosing them in inverted commas. Use the period as the decimal point character. See also the examples listed below.
    Units of measurement: The following units of measurement may be used:
    TW (twip)
    PT (point)
    IN (inch)
    MM (millimeter)
    CM (centimeter)
    LN (line)
    CH (character).
    The following conversion factors apply:
    1 TW = 1/20 PT
    1 PT = 1/72 IN
    1 IN = 2.54 CM
    1 CM = 10 MM
    1 CH = height of a character relative to the CPI specification in the form header
    1 LN = height of a line relative to the LPI specification in the form header
    /: BOX FRAME 10 TW
    Draws a frame around the current window with a frame thickness of 10 TW (= 0.5 PT).
    /: BOX INTENSITY 10
    Fills the window background with shading having a gray scale of 10 %.
    /: BOX HEIGHT 0 TW FRAME 10 TW
    Draws a horizontal line across the complete top edge of the window.
    /: BOX WIDTH 0 TW FRAME 10 TW
    Draws a vertical line along the complete height of the left hand edge of the window.
    /: BOX WIDTH '17.5' CM HEIGHT 1 CM FRAME 10 TW INTENSITY 15
    /: BOX WIDTH '17.5' CM HEIGHT '13.5' CM FRAME 10 TW
    /: BOX XPOS '10.0' CM WIDTH 0 TW HEIGHT '13.5' CM FRAME 10 TW
    /: BOX XPOS '13.5' CM WIDTH 0 TW HEIGHT '13.5' CM FRAME 10 TW
    Draws two rectangles and two lines to construct a table of three columns with a highlighted heading section.
    POSITION Command
    Syntax
    /: POSITION [XORIGIN] [YORIGIN] [WINDOW] [PAGE]
    Effect: Sets the origin for the coordinate system used by the XPOS and YPOS parameters of the BOX command. When a window is first started, the POSITION value is set to refer to the upper left corner of the window (default setting).
    Parameters: If a parameter value does not have a leading sign, then its value is interpreted as an absolute value, in other words, as a value that specifies an offset from the upper left corner of the output page. If a parameter value is specified with a leading sign, then the new value of the parameter is calculated relative to the old value. If one of the parameter specifications is missing, then no change is made to this parameter.
    XORIGIN, YORIGIN
    Origin of the coordinate system.
    WINDOW
    Sets the values for the left and upper edges to match those of the current window (default setting).
    PAGE
    Sets the values for the left and upper edges to match those of the current output page (XORIGIN = 0 cm, YORIGIN = 0 cm).
    /: POSITION WINDOW
    Sets the origin for the coordinate system to the upper left corner of the window.
    /: POSITION XORIGIN 2 CM YORIGIN '2.5 CM'
    Sets the origin for the coordinate system to a point 2 cm from the left edge and 2.5 cm from the upper edge of the output page.
    /: POSITION XORIGIN '-1.5' CM YORIGIN -1 CM
    Shifts the origin for the coordinates 1.5 cm to the left and 1 cm up.
    SIZE Command
    Syntax
    /: SIZE [WIDTH] [HEIGHT] [WINDOW] [PAGE]
    Effect: Sets the values of the WIDTH and HEIGHT parameters used in the BOX command. When a window is first started, the SIZE value is set to the same values as the window itself (default setting).
    Parameters: If one of the parameter specifications is missing, then no change is made to the current value of this parameter. If a parameter value does not have a leading sign, then its value is interpreted as an absolute value. If a parameter value is specified with a leading sign, then the new value of the parameter is calculated relative to the old value.
    WIDTH, HEIGHT
    Dimensions of the rectangle or line.
    WINDOW
    Sets the values for the width and height to the values of the current window (default setting).
    PAGE
    Sets the values for the width and height to the values of the current output page.
    /: SIZE WINDOW
    Sets WIDTH and HEIGHT to the current window dimensions.
    /: SIZE WIDTH '3.5' CM HEIGHT '7.6' CM
    Sets WIDTH to 3.5 cm and HEIGHT to 7.6 cm.
    /: POSITION WINDOW
    /: POSITION XORIGIN -20 TW YORIGIN -20 TW
    /: SIZE WIDTH +40 TW HEIGHT +40 TW
    /: BOX FRAME 10 TW
    A frame is added to the current window. The edges of the frame extend beyond the edges of the window itself, so as to avoid obscuring the leading and trailing text characters.
    http://esnips.com/doc/1ff9f8e8-0a4c-42a7-8819-6e3ff9e7ab44/sapscripts.pdf
    http://esnips.com/doc/1e487f0c-8009-4ae1-9f9c-c07bd953dbfa/script-command.pdf
    http://esnips.com/doc/64d4eccb-e09b-48e1-9be9-e2818d73f074/faqss.pdf
    http://esnips.com/doc/cb7e39b4-3161-437f-bfc6-21e6a50e1b39/sscript.pdf
    http://esnips.com/doc/fced4d36-ba52-4df9-ab35-b3d194830bbf/symbols-in-scripts.pdf
    http://esnips.com/doc/b57e8989-ccf0-40d0-8992-8183be831030/sapscript-how-to-calculate-totals-and-subtotals.htm
    Regards
    Anji

Maybe you are looking for

  • IK Bone Tool Bones are not Displaying

    This may be a very dumb question, but how do you get the bones to display? I have connected 5 graphics together with the bone tool, but when I was clicking and dragging the bones did not appear. The armature was created and I can click and drag them

  • /usr/bin/java Permission denied after installing JDK on linux

    Hi Guys, I installed jdk-6u1-linux-i586-rpm.bin and I am getting strange errors like this: 1 When I simply run "java" in shell I get this: /usr/bin/java: line 67: /tmp/javaf10273: Permission denied /usr/bin/java: line 67: /tmp/javaf10273: Success 2.

  • [svn:fx-trunk] 10647: * A batch of compiler fixes.

    Revision: 10647 Author:   [email protected] Date:     2009-09-28 10:21:59 -0700 (Mon, 28 Sep 2009) Log Message: A batch of compiler fixes. QE notes: Doc notes: Bugs: SDK-22258, SDK-21547, SDK-22879, SDK-23169, SDK-23336 Reviewer: Edwin (ActionFactory

  • Distributing Application For FieldPoint

    I have developed an application for Fieldpoint. I want to distibute it in binary format. I want to make use of FieldPoint Explorer's Install/Remove Software feature for deploying application. Is there any documentation from NI for making Installation

  • How to call repaint() from one panel for another panel

    I have two classes (leftPanel and rightPanel), which extends JPanel. I have added these panels to the container of the JFrame. I have a JButton in my left leftPanel. When I click the button I want that the repaint method of rightPanel is called. Plea