Application Development and Automation 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: 
Read only

Printing Strings in SAP Scripts

Former Member
0 Likes
840

Hello

I need to print a string in Script that is not defined anywhere in the script.

example, I need to print 60 CAD/ 100 LE.

I have text symbols for all these(60,CAD,100,LE) values except '/'.How can I print this in Script. Help me with the syntax.

Thanks

Tharani

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
734

Hi,

With out assigning this string to text symbol you can do directly in code.

LIke:

/: <K1>60,CAD,100,LE</>

This you can place where ever you want.

K1 is character format(create it).

/: is paragraph format you can use your own also.

I hope it will sove your problem.

Thanks.

6 REPLIES 6
Read only

Former Member
0 Likes
734

U WILL HAVE TO CODE FOR HTAT IN HTE SCRIPT,

REGARDS,

KARTIKEY.

Read only

Former Member
0 Likes
735

Hi,

With out assigning this string to text symbol you can do directly in code.

LIke:

/: <K1>60,CAD,100,LE</>

This you can place where ever you want.

K1 is character format(create it).

/: is paragraph format you can use your own also.

I hope it will sove your problem.

Thanks.

Read only

0 Likes
734

These 60,CAD and all those values will keep on changing for each scenario.So I have included in symbol. Please tell me how to include this sysmbol '/' in the script

Thanks

tharani

Read only

0 Likes
734

Hi,

Try giving that symbol in between that.

I never had this type of requirement.

If not I think with 'IF' conditions you have to go for displaying the texts.

Thanks.

Read only

Former Member
0 Likes
734

I think u can print / as it is.

i.e after text symbols of 60 and CAD specify / and then text symbols of 100 and LE.

Read only

Former Member
0 Likes
734

Maybe you can try this:

/: DEFINE &CH1& = '60'.

/: DEFINE &CH2& = 'CAD'.

/: DEFINE &CH3& = '100'.

/: DEFINE &CH4& = 'LE'.

/: DEFINE &LOM& = '/'.

/: DEFINE &CH& = '&CH1& &CH2& &LOM& &CH3& &CH4&'.

/ &CH&