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

TAB Separator issue in script

Former Member
0 Likes
1,531

Hi All,

I have created a script for displaying data. I have also created paragraphs for displaying the item level data column wise (using the tab separator concept in scripts).

The problem i am facing is: Sometimes my material text will have data like 'SUGAR,,SALT'.

The ,, between my material description is making the tab to skip to the next column and print SALT below the next column heading.

How can I avoid this problem and print 'SUGAR,,SALT' below one column itself than making it jump to the next tab.

thanks and regards

Shilpa

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
1,380

well you might make use of the raw text format.

in sap script use "<(>BLA,,BLA<)>".

your output will be BLA,,BLA.

Everything between <(> and <)> will be printed like it is, no tags will be recognized from system.

Problem is, you cannot do it like <(>&VARIABLE&<)>, cause your & will be ignored as well, hmmm not really ignored but printed.

so you in your case you´d need to generate <(> and <)> into your variable.

like :

concatenate '<(>' variable '<)>' into variable.

this should work.

11 REPLIES 11
Read only

Former Member
0 Likes
1,380

Hi,

If your material contains double comma , just replace with dots and pass it to text symbol in the print program itself.

Regards,

Nandha

Read only

0 Likes
1,380

But if I replace it with .. then also it will be a problem, as i will not be getting the correct data. Finally i need is 'SUGAR,,SALT' in one column.

Read only

Former Member
0 Likes
1,380

hi

Have u tried "no-seprator"?

Regards.

Read only

0 Likes
1,380

Hi,

I am not clear on this No-Separator concept in script. Can you please throw more light on this.

Shilpa

Read only

Former Member
0 Likes
1,380

Hi,

IN the driver program concatenate the texts ( sugar salt) sepereated by ,, into var1.

var1 = SUGAR,,SALT.

Now you can use this var1 in script whicn wont conisder ,, as tab space.

regards,

Naveen

Edited by: Naveen Deva on Mar 5, 2009 11:43 AM

Read only

0 Likes
1,380

Hi Naveen,

I Had tried that putting each part in quotes.. but the user wants is without quotes i.e. SUGAR,,SALT.

Sorry I should have been clear with this in my query.

thanks and regards

Shilpa

Read only

0 Likes
1,380

Hi,

I am sure you will displaying the material description thru variable in script ( and not hardcoded) in this case it wont consider ,, as tab space.

if you hardcode SUGAR,,SALT. then it will split ....

Check it ones again there might be some other problem

Regards,

Naveen

Read only

0 Likes
1,380

HI Naveen

I am displaying the value from a work area field e.g. wa_final-description. This wa_final-description has value = SUGAR,,SALT.

And also i check by changing my tab positions and the SALT was getting printed correctly at the next tab position. This is how i realized that the shift was due to ,, being in between my data description. If i make it as SUGAR,SALT then it gets correctly displayed under one column.

So the problem for sure is due to the ,,

But i am not able to get any idea of how to correct it. Pl help.

Thanks and regards

Shilpa

Read only

Former Member
0 Likes
1,380

Hi

Shilpa

Declare the paragraph format and give tab space to it

Try with the following

You declare both SUGAR,,SALT as one word dont mention any tab space between these two words.

and also check your window size .

Hope this solve your issue

Regards,.

Rajani

Read only

Former Member
0 Likes
1,380

hi,

Tyr it this way,

'SUGAR' ',,' 'SALT '

This may solve your problem.

Thanks and Regards

Suraj Nair

Read only

Former Member
0 Likes
1,381

well you might make use of the raw text format.

in sap script use "<(>BLA,,BLA<)>".

your output will be BLA,,BLA.

Everything between <(> and <)> will be printed like it is, no tags will be recognized from system.

Problem is, you cannot do it like <(>&VARIABLE&<)>, cause your & will be ignored as well, hmmm not really ignored but printed.

so you in your case you´d need to generate <(> and <)> into your variable.

like :

concatenate '<(>' variable '<)>' into variable.

this should work.