on 11-10-2008 2:00 PM
Hello Experts,
I am having an error in my code below:
SAPSCRIPT:
Begin of insertion DEVK940799 11/10/2008 DEL_HIDALGO
DEFINE <YC_NAME1& = ''.
DEFINE <YC_NAME2& = ''.
DEFINE <YC_STR_SUPPL1& = ''.
DEFINE <YC_STR_SUPPL2& = ''.
DEFINE <YC_STR_SUPPL3& = ''.
DEFINE <YC_POST_CODE1& = ''.
DEFINE <YC_CITY1& = ''.
DEFINE <YC_BEZEI& = ''.
DEFINE <YC_LAND1& = ''.
PERFORM GET_VENDOR_DETAILS IN PROGRAM Z9999RFI_Z2574FFI_RA
USING ®UH-LIFNR&
CHANGING <YC_NAME1&
CHANGING <YC_NAME2&
CHANGING <YC_STR_SUPPL1&
CHANGING <YC_STR_SUPPL2&
CHANGING <YC_STR_SUPPL3&
CHANGING <YC_POST_CODE1&
CHANGING <YC_CITY1&
CHANGING <YC_BEZEI&
CHANGING <YC_LAND1&
ENDPERFORM
<YC_NAME1& <YC_NAME2&
<YC_STR_SUPPL1&
<YC_STR_SUPPL2&
<YC_STR_SUPPL3&
<YC_POST_CODE1&
<YC_CITY1&
<YC_BEZEI&
<YC_LAND1&
End of insertion DEVK940799 11/10/2008 DEL_HIDALGO
PROGRAM:
*&---------------------------------------------------------------------*
*& Report Z9999RFI_Z2574FFI_RA
*&
*&---------------------------------------------------------------------*
*&
*&
*&---------------------------------------------------------------------*
REPORT z9999rfi_z2574ffi_ra.
*&---------------------------------------------------------------------*
* Start of Selection event
*&---------------------------------------------------------------------*
START-OF-SELECTION.
*&---------------------------------------------------------------------*
*& Form get_vendor_details
*&---------------------------------------------------------------------*
* text
*----------------------------------------------------------------------*
* -->IM_LIFNR text
* -->CH_NAME1 text
* -->CH_NAME2 text
* -->CH_STR_SUPPL1 text
* -->CH_STR_SUPPL2 text
* -->CH_STR_SUPPL3 text
* -->CH_POST_CODE1 text
* -->CH_CITY1 text
* -->CH_BEZEI text
* -->CH_LAND1 text
*----------------------------------------------------------------------*
FORM get_vendor_details USING im_lifnr
CHANGING ch_name1 TYPE adrc-name1
ch_name2 TYPE adrc-name2
ch_str_suppl1 TYPE adrc-str_suppl1
ch_str_suppl2 TYPE adrc-str_suppl2
ch_str_suppl3 TYPE adrc-str_suppl3
ch_post_code1 TYPE adrc-post_code1
ch_city1 TYPE adrc-city1
ch_bezei TYPE bezei
ch_land1 TYPE t005-land1.
DATA: ltyc_adrnr TYPE lfa1-adrnr.
SELECT SINGLE adrnr
FROM lfa1
INTO ltyc_adrnr
WHERE lifnr = im_lifnr.
IF sy-subrc = 0.
CALL FUNCTION 'CONVERSION_EXIT_ALPHA_INPUT'
EXPORTING
input = ltyc_adrnr
IMPORTING
output = ltyc_adrnr.
SELECT SINGLE name1 name2 str_suppl1
str_suppl2 str_suppl3 post_code1
city1
FROM adrc
INTO (ch_name1, ch_name2, ch_str_suppl1,
ch_str_suppl2, ch_str_suppl3, ch_post_code1,
ch_city1)
WHERE addrnumber = ltyc_adrnr.
ENDIF.
ENDFORM. "get_names
It says that there is an error in perform but they both have the same number of parameters.
Sorry, Check the link Eric has posted below.
Regards
Karthik D
Edited by: Karthik D on Nov 10, 2008 7:48 PM
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
This message was moderated.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
the PERFORM statement works differently in SAPScript, pls. check in SAPHelp:
http://help.sap.com/saphelp_46c/helpdata/en/d1/803279454211d189710000e8322d00/frameset.htm
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Thanks again Eric!,
By the way, I am doing the check printing program for F110 and F-58. Is it ok to customize the standard program RFFOUS_C? And I was wondering on why some of my variables are not showing their values in my windows well in fact it has one when I debug the driver program and some appear as 'XXXXXXXXXX' in the layout...
What do you mean by "Is it ok to customize the standard program RFFOUS_C"? I think you only have to copy a standard SAPScript for checks (if there is any...) and modify it acc. to your requirements. In the system you can customize that the standard print program will call your Z... SAPScript.
On the other hand I believe that all variables you want to use in the SAPScript has to be defined in as global in the print program (except the ones, which you define in the script (with DEFINE))
User | Count |
---|---|
76 | |
9 | |
8 | |
7 | |
6 | |
5 | |
5 | |
5 | |
5 | |
5 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.