on 08-07-2009 9:02 AM
Hi all,
In the sapscript
i have an include standard text as below
C1 Text 1
/: INCLUDE Z_TEST OBJECT TEXT ID SDVD PARAGRAPH C1
C1 Text 2
the problem is if the Z_TEST is empty , it will auto supress the line with Z_TEST
result is :
Text 1
Text 2
However , i would like to have a result with a blank line in bewteen
expected result
Text 1
<blank line>
Text 2
PS: Paragraph C1 has already uncheck "no blank lines" option
Would anyone give me some tricks for doing the above requirements
Thanks in advance
David Tai
Hi,
You can test if this include exist or not.
&SAPSCRIPT-SUBRC&
After executing an INCLUDE statement, this contains a value that indicates whether the INCLUDE was found or not. This value can be queried with IF....
INCLUDE found = 0 and INCLUDE not found = 4
So you must do the following
C1 Text 1
i/: INCLUDE Z_TEST OBJECT TEXT ID SDVD PARAGRAPH C1
/: if &SAPSCRIPT-SUBRC& eq 4
/: endif.
C1 Text 2
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
really thanks both of you!
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
Goto SO10 Tcode, Open your Z_TEST
In the text give space, by pressing Alt Key + 255( Ascii format which is equal to a Space)
So the text in Standard text will be blank but as it is a ASCII space in output it will not take as a blank line, so your requirment will work. i tested it, it is working fine.
For testing Just open Notepad and press following
ALT key + 85 = U
ALT key + 86 = V
ALT key + 255 = Space
Regards
Bala Krishna
Edited by: Bala Krishna on Aug 7, 2009 2:01 PM
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
85 | |
10 | |
10 | |
9 | |
6 | |
6 | |
6 | |
5 | |
4 | |
3 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.