Add lines to SAP sapscript form via tcode SE71

The following steps show you how to add black lines to an existing SAPScript form/document within your SAP system.

Step 1 - Execute transaction SE71 and create a basic form
Use an existing form you have already created or see Create basic form for more details on creating your first sapscript form.

Step 2 - Create new window
Now select the windows tab/button, any existing windows should be displayed here. Simply enter the name of your new window (i.e. BOXES ) in the input field at the bottom of the screen and press enter.


Within the popup option window choose 'Create New Window' and press select.


Now give your window a Meaning/Description


Step 3 - Update text elements to add lines
Now still within the windows tab/section ensure that the new BOXES window is selected and press the 'Text Elements' button.


If you are going to paste the below code you will need to create a number(22) of command lines denoted by the '/:' symbol. To do this simply use the dropdown at the start of each line.


Step 4 - Add code to draw lines on the sapscript form
Now simply copy and paste the below code onto the first command line you just created('/:')

BOX FRAME 10 TW
BOX YPOS 14 MM HEIGHT 9 MM FRAME 10 TW
BOX YPOS '30.1' MM HEIGHT '6.3' MM FRAME 10 TW
BOX YPOS '42.7' MM HEIGHT '6.3' MM FRAME 10 TW
BOX YPOS '55.3' MM HEIGHT '6.3' MM FRAME 10 TW
BOX YPOS '67.9' MM HEIGHT '6.3' MM FRAME 10 TW
BOX YPOS '80.5' MM HEIGHT '6.3' MM FRAME 10 TW
BOX YPOS '93.1' MM HEIGHT '6.3' MM FRAME 10 TW
BOX YPOS '105.7' MM HEIGHT '6.3' MM FRAME 10 TW
BOX YPOS '118.3' MM HEIGHT '6.3' MM FRAME 10 TW
BOX YPOS '130.9' MM HEIGHT '6.3' MM FRAME 10 TW
BOX YPOS '143.5' MM HEIGHT '6.3' MM FRAME 10 TW
BOX YPOS '156.1' MM HEIGHT '6.3' MM FRAME 10 TW
BOX YPOS '168.7' MM HEIGHT '6.3' MM FRAME 10 TW
BOX YPOS '181.3' MM HEIGHT '6.3' MM FRAME 10 TW
POSITION WINDOW
SIZE WINDOW
BOX XPOS 165 MM YPOS 14 MM WIDTH 33 MM HEIGHT '173.6' MM FRAME 10 TW
BOX XPOS 198 MM YPOS 14 MM WIDTH 20 MM HEIGHT '173.6' MM FRAME 10 TW
BOX XPOS 179 MM YPOS 14 MM WIDTH 46 MM HEIGHT '173.6' MM FRAME 10 TW
BOX XPOS 225 MM YPOS 14 MM WIDTH 17 MM HEIGHT '173.6' MM FRAME 10 TW
BOX XPOS 251 MM YPOS 14 MM WIDTH 17 MM HEIGHT '173.6' MM FRAME 10 TW



Step 5 - Update Page Window
Now click on the Page Windows tab/button and add your new page to your window via the 'Edit->Create Element...' option

Double click on your new boxes window within the popup


Now enter width and height


Step 6 - Save and activate


Step 7 - Test
Test your new form using the 'Utilities->Printing Test' option


You should see a blank page


Related Articles

Create basic SAPScript document using transaction SE71
SAPScript Development Info - Example code and information on various areas of SAPScript development
Debug SAPscript form
Execute ABAP code from within SAPScript code
SAPscript function modules used to populate form
Maintenance and implementation of SAPScript texts in SAP
Start SAPScript document on specific page number
SAP standard texts Object and Text id details required to retrieve value
Maintenance and implementation of standard texts or SAPSCript texts