‎2014 Jan 16 7:00 AM
i created one sap script, and used the BOX command and inside the box i insert the text , but text is appearing on the box lines can any one tell me how to align text to protect not to be appear on the lines .below is my situation.
this box like this in sap script.
| Description | Amount |
|---|---|
| sample text sample tecxtttttttt | 2300 |
i successfully created BOX like above but text inside the box is appearing on the lines .
thanks
‎2014 Jan 16 7:47 AM
Hi,
you can use
BOX Command
Parameters: For each of XPOS, YPOS, WIDTH, HEIGHT and FRAME both a measurement and a unit of measurement must be specified. The INTENSITY parameter should be specified as a percentage between 0 and 100.
1. 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
2. WIDTH: Width of the box. Default: WIDTH value of the SIZE command.
3. HEIGHT: Height of the box. Default: HEIGHT value of the SIZE command.
4. FRAME: Thickness of frame. Default: 0 (no frame).
5. INTENSITY: Grayscale of box contents as % .
pls check this link
‎2014 Jan 16 7:51 AM
‎2014 Jan 16 7:56 AM
Dear i already tried but my issue is the text inside the box is appearing on line of box
and text is dynamic i dont know how much length each time
‎2014 Jan 16 8:04 AM
Hi Jamal,
the only way is either chop the text to a particular length and append it to new line
OR
Determine the length or number of characters in the string using string length and move or change the position of the vertical line dynamically
Hope this helps!
Happy Coding,
Santhosh Yadav
‎2014 Jan 16 8:13 AM
‎2014 Jan 16 8:30 AM
Hi Jamal,
Find the length of the text using Finding the Length of a Character String (SAP Library - ABAP Programming (BC-ABA))
then set the attributes ie; width of the BOX dynamically using http://scn.sap.com/thread/1610340
If you are fine with this please mark the thread answered and close the thread.
Happy Coding,
Santhosh Yadav
‎2014 Jan 20 2:09 PM
Hi Jamal,
your issue must be resolved by using the sap standard " &SAPSCRIPT-COUNTER_0& "
Please try the solution provided by me way back in 2007 in saptechnical.com
SAPTechnical.COM - Printing internal table contents dynamically
Let me know,if you face any problems.
Btw i agree that the heading was not in sync with the solution provided .
-
Lakshmi