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

sapscript RVORDER01

Former Member
0 Likes
1,206

Hello,

Sapscript name is RVORDER01 . How to add KNA1-STCD1 in the sapscript without changing the print program.

Tried with subroutine , does not work . Any other suggestions.

Mona

9 REPLIES 9
Read only

Former Member
0 Likes
1,166

Hi,

Post your subroutine program code.

Read only

0 Likes
1,166
Read only

0 Likes
1,166

It appears that the below query is getting failed.

Use the FM 'CONVERSION_EXIT_ALPHA_INPUT' to convert the customer into internal format

SELECT SINGLE STCD1

                 FROM  KNA1 INTO (V_STCD1)

                 WHERE KUNNR = INTAB-VALUE.

Follow the below approach. Use conversion routine to convert customer into internal format.

DATA: kunnr type kunnr.

CALL FUNCTION 'CONVERSION_EXIT_ALPHA_INPUT'
  EXPORTING
    input         = kunnr
IMPORTING
   OUTPUT        = kunnr .

SELECT SINGLE STCD1

                 FROM  KNA1 INTO (V_STCD1)

                 WHERE KUNNR = KUNNR.

Read only

0 Likes
1,166

Thanks Vijay,

Just one question . Should I add the FM in the subroutine code

DATA: kunnr type kunnr.

CALL FUNCTION 'CONVERSION_EXIT_ALPHA_INPUT'
  EXPORTING
    input         = kunnr
IMPORTING
   OUTPUT        = kunnr .

SELECT SINGLE STCD1

                 FROM  KNA1 INTO (V_STCD1)

                 WHERE KUNNR = KUNNR.

Mona

Read only

0 Likes
1,166

Yes. You should add the FM in the subroutine code.

Read only

eduardo_hinojosa
Active Contributor
0 Likes
1,166

Hi Mona,

See this link: http://help.sap.com/saphelp_40b/helpdata/EN/d1/803279454211d189710000e8322d00/content.htmhttp://

Of course, you need to create a customer SAPscript (for instance ZRVORDER01) and change the settings in output message for sales orders.

I hope this helps you

Regards

Eduardo

Read only

0 Likes
1,166

hello,

here is the link to my previous question, did nt get any solution so i posted it again.

http://scn.sap.com/thread/3347286

mona

Read only

0 Likes
1,166

Hello,

put a break point in the program where you wrote the routine that gets the STCD1 in SE38, so debbug it and check if you get the value of the STCD1.

Start doing that

Regards

Read only

0 Likes
1,166

Hi

Instead &KNA1-KUNNR& write &KNA1-KUNNR(K)&, so, you will prevent the conversion with the command (K). Think that SAP transfer to the subroutine with the first option without the zeros in the left.

Regards

Eduardo