‎2005 Sep 14 10:30 PM
Hi,
I am displaying a list of items on a SAPSCRIPT form but the item's fields are not align with the heading when the fields' lengths vary. For example, if one of the fields is 3 chars short then the subsequence fields will be shifted left by 3 spaces.
Is there a way to define a field to start at a fixed position in SAPSCRIPT with regardless to its actual length? Please help!
Best regards,
Chuong Le
‎2005 Sep 14 11:38 PM
Hi Chuong,
What you need to do is define "Paragraph Formats" for your SAPscript. These Paragraph Formats define your font and tab definitions.
You create these paragraph formats via SE71 and are SAPscript specific. Let's say for example, you want to create a simple 2 column report in TIMES 12 font.
Go to SE71 and open up your SAPscript. CLick on the "Paragraph Format" button on the Application Toolbar. Create a new Paragraph Format and let's call it "Z1".
You will see the attributes to the Paragraph Format at the bottom of the screen. CLick on the "Font" button to define your TIMES in your Font Family and 12 as your Font Size.
Now go to the "Tabs" button and here you define your column widths. These are your Column Separators. Because we are only defining 2 columns, you only need to define 1 tab. Lets make it at 20 CH (CH means characters), and left aligned.
Save your Paragraph Format.
Now to use your Paragraph Format in your SAPscript Editor. Let's say you want to use it in Text Element 'Heading' to display Material Number and Old Material Number:
/E HEADING
Z1 &MARA-MATNR&,,&MARA-BISMT&
The ",," tells the SAPscript that you want a "Tab" here.
Hope this makes sense.
Cheers,
Pat.
PS. Kindly assign Reward Points to the posts you find helpful.
‎2005 Sep 14 11:38 PM
Hi Chuong,
What you need to do is define "Paragraph Formats" for your SAPscript. These Paragraph Formats define your font and tab definitions.
You create these paragraph formats via SE71 and are SAPscript specific. Let's say for example, you want to create a simple 2 column report in TIMES 12 font.
Go to SE71 and open up your SAPscript. CLick on the "Paragraph Format" button on the Application Toolbar. Create a new Paragraph Format and let's call it "Z1".
You will see the attributes to the Paragraph Format at the bottom of the screen. CLick on the "Font" button to define your TIMES in your Font Family and 12 as your Font Size.
Now go to the "Tabs" button and here you define your column widths. These are your Column Separators. Because we are only defining 2 columns, you only need to define 1 tab. Lets make it at 20 CH (CH means characters), and left aligned.
Save your Paragraph Format.
Now to use your Paragraph Format in your SAPscript Editor. Let's say you want to use it in Text Element 'Heading' to display Material Number and Old Material Number:
/E HEADING
Z1 &MARA-MATNR&,,&MARA-BISMT&
The ",," tells the SAPscript that you want a "Tab" here.
Hope this makes sense.
Cheers,
Pat.
PS. Kindly assign Reward Points to the posts you find helpful.