Application Development and Automation Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

Script: tabs, boxes, tables

Former Member
0 Likes
684

hi all

i am creating a script for delivery note.

Address of ship-to-party in right window at top.

Logo in left window at top.

Under that in middle Delivery Ord. No:XXXXX

Then in the item level i need to display in the following format


------------------------------------------------
|ITEM  |MATERIAL    |QTY     |PRICE   |CURRENCY | <-Headr
------------------------------------------------
| xxxx |xxxxx       |xxxx    |xxxx    |xxxx     | <-Item
| xxxx |xxxxx       |xxxx    |xxxx    |xxxx     | .
| xxxx |xxxxx       |xxxx    |xxxx    |xxxx     | .
| xxxx |xxxxx       |xxxx    |xxxx    |xxxx     | .
| xxxx |xxxxx       |xxxx    |xxxx    |xxxx     | <-Item
-------------------------------------------------
                 Total Amount xxxx

<b>My Questions are</b>

1) how to specify the tabs for these items

ITEM is 6, MATERIAL is 18, QTY is 15, PRICE is 13, CURRENCY is 15 Charaters length and give how to code in textelement

2) How to specify the box for these layout, i mean we dont know how many item data will be there. how to specify box for that

Help me out please

3 REPLIES 3
Read only

Former Member
0 Likes
482

check these links,you can findout about boxes...

http://www.sap-img.com/sapscripts.htm

http://www.henrikfrank.dk/abapexamples/SapScript/sapscript.htm

and also,

Regards,

Srikanth

Read only

Former Member
0 Likes
482

HI,

1) how to specify the tabs for these items

In the Paragraph format....

select the TABS button and give the tabpositions..

in text element..

specify the paragraph format for which tabs are defined and give comma's for tab space..

ex:

p1 &f1&,,&f2&

2) Box Command

/: 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.

hope this helps,

do reward if it helps,

priya.

Read only

Former Member
0 Likes
482

Hi,

1. Tab spaces can be set in when u are creating the paragraph format for that particular items.

2.Coming to the box this is little complex.

The first thing u have to do is calcualte dynmically the no of item records.

For example in ur loop u are getting 5 items,so u have to calculate the hegight of box based on no of records.

In this case 5 records, multiply this no of records with some constant and pass them into varible.And now u can use this varible in the box statment in ur form.

Example:

BOX XPOS '0' CM WIDTH '18.5' CM HEIGHT &G_F_COUNT20& CM FRAME 2 TW

In the above example G_F_COUNT20 height calculated in the program.

One thing should be rembered the G_F_COUNT20 varible should be declared in chracter format.

Let me know if I am not clear.

Regards