Application Development 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: 

Internal Table to string variable in SO10 used in smartforms

Former Member
0 Kudos

Hello all,

I searched SDN and found the below threads that have my exact problem but no solution is provided. Hence posting the question again.

http://scn.sap.com/thread/1028641
http://scn.sap.com/thread/134070
http://scn.sap.com/thread/2131226

Scenario: We use SO10 standard text in smartform. I need to pass an internal table to a variable in SO10 object. so I concatenate data of internal table into a string variable which is directly used in SO10 object.

Issue: When I am checking in debugging, in "Fast Display" mode all the contents are not getting displayed while I am checking in "Tabular" mode all the contents are getting displayed. When the same variable is displayed in correspondence email (SO10 used in smartform) the text displayed in "Fast Display" only is coming in email and all the remaining text is getting truncated.

Request you to please help me resolve this issue. Please let me know if I need to provide any further details. Thanks in advance for all your help.

Regards,

Eswar

6 REPLIES 6

Private_Member_49934
Contributor
0 Kudos

Hi Eshwar, Why do you want to do so much hard work to display so10 text?

When you create a new text in smartform, you have something call type. If you choose it as I ( Include Text ) You can enter the SO10 text name directly or through variable

Text Name       Your SO10 text name

Language        EN

Text ID         ST   Standard text

Text Object     TEXT       SAPscript standard text

0 Kudos

Hi Gaurav,

That is exactly what I am doing. Please see the below screenshot.

Below is the screenshot of the SO10 object.

The string variable is GV_STRING and I need to pass an internal table data to this GV_STRING string variable.

Request you to please help me in this regard.

Thanks,

Eswar

0 Kudos

Hi Eswar.

I went thorough the fm which are used for replacing the text symbols TEXT_SYMBOL_REPLACE / TEXT_SYMBOL_SET_VALUE. They are all in FG STXE ( SAPscript Programing interface ).

Upon digging down I found that the table which is used to contain the replacement is in include LSTXVDXX.

   data:
begin of itcvl occurs 0,
   name(c_ts_len),                     "...Textsymbol-Name
   active(1),                          "...Eintrag aktiv
   val(c_ts_maxval),                   "...Wert eines Textsymbols
   len like integer,                   "...Wertlaenge
end of itcvl.

Furthe the val field has max leng as 80 which means Your text symbol can replace max upto 80 CHARACTERS only. Bad news for you but this is waht it appears to be

    c_ts_maxval  type i value 80,                  " max text symbol value



0 Kudos

Hi Gaurav,

Thanks a lot for your help. But 80 characters should not be an issue. I can display 10 rows each of 80 chars length by using a line feed which is currently working for me. The problem I am facing is, gv_string after concatenating 4 or so lines, its reaching max length and everything concatenated after that is simply getting truncated.

Regards,

Eswar

Former Member
0 Kudos

hi,

Fetch the SO10 text in an internal table and

then display this internal table line by line.using the text module.

regards.

Former Member
0 Kudos

Thank you all for your responses. We contacted SAP and SAP came back saying the max length in Scripts & Smartforms for a text variable is 256 chars and hence that is the max value. So we have removed using the FM in our program and used Replace command to replace the text manually.

Regards,

Eswar