‎2008 May 02 12:58 PM
I am working on the Smartforms, In that smartforms i am using READ_TEXT Function Module to get the Texts.
Once I get the text in internal table , I need to print it in smartform.
But as we can print in sap script, it not getting printed in smart form for control character ex. bold, underline and italics... it simply printing text with control characters.
Regards
Manglesh
‎2008 May 02 1:00 PM
Hi, You can format it using character formats.
Regards,
Vijayalakshmi
‎2008 May 02 1:00 PM
Hi, You can format it using character formats.
Regards,
Vijayalakshmi
‎2008 May 02 1:03 PM
Hi Vijaya ,
Please find my question in detail .
I'm working on the Smartforms, In that smartforms i'm using READ_TEXT Function Module to get the Texts.
Once I get the text in internal table , I need to print it in smartform. But as we can print in sap script, it not getting printed in smart form for control character...
Ex : if we get data in GT_TILE table from read text function module
GT_LINE-TDLINE = '<H><.U> text <./><./>'.
and if I will put in smartform editor '&'GT_LINE-TDLINE'&',
Then It was not printing in bold and under line in smartform..
It was simply printing with control characher as
<H> <.U> text </></>.
Hence I am reading each line and then saparating string into two parts before and after the control chars.. and explicitly putting in editor as below
Str1 = -
str2 = <h><.U> text <./><./>.
then replacing <H> , <.U> <./><./>, with space. and then
str2 = text
and then making explicity in
< H > <. U> &str2 & <./><./> .
Then its printing in bold and under line...
But if bold or underline is in betn the string, then it won't work..
ex : 2. TBO H Always TBC PUT 2 STEETS PAPER BETN THE SLING AND ROLL COVER.
then my logic won't work, it will print complete str2 in bold.
Regards
Manglesh
‎2008 May 02 1:10 PM
Hi,
Is there a particular reason why you're not using an include text for this object, rather than the function module READ_TEXT? Create a text node and change the type to 'include text', then enter the values of name, object and id that you are currently passing to READ_TEXT.
Regards,
Nick
‎2008 May 02 1:49 PM
Hi Nick,
I am getting those data from long text of work order description.
That data I am reading using READ_TEXT function module and then trying to print in smart form.
Hence I can not use include text.
Please suggest.
Regards
Manglesh
‎2008 May 02 2:08 PM
Hi,
I understand what you are doing but I don't see how you conclude you can't use an include text.
Both the text in your work order and that of a SAPscript include text are stored in the same way, and are identified by OBJECT, NAME, ID, and LANGUAGE. Your function module READ_TEXT will read both the work order text or a SAPscript include text and you can view them both in SO10.
Create a text node in the smartform and change the type to include text. Take the OBJECT, NAME, ID, and LANGUAGE of your work order and put them in the Text key fields.
Regards,
Nick
‎2008 May 02 2:46 PM
Thanks Nick,
Its working for all control characher...
But I have one more problem outcome..
If you see below paragraph.
6. INSTALL FRONT END JOURNAL EXTENSION WITH 1 1/2" SOCKET HEAD
CAPSCREWS.
NEW-PAGE
7. RIG TENDING END OF ROLL TO JOURNAL EXTENSION WITH NORTH
There is * NEW-PAGE ...
If it occurs, then I have to make page break explicitly.. There is no '/:' commmand is getting used.
Hence in my previous logic I was reading each record of Read_text function module internal table and if I get PAGE-BREAK, then I was explicitly doing page break.
So if you are aware, pls help.
Regards
Manglesh
‎2008 May 02 1:10 PM
Hi, Try using replace all occurences of <H> or <U> in TDLINE.
Regards,
Vijayalakshmi
‎2008 May 02 1:50 PM
Thanks Vijaya,
Could you please describe in details.
Regards
Manglesh