on 2009 Feb 28 6:59 AM
Hello,
I have to upload vendor master. Everything gets uploaded except the email of the vendor. I have tried several ways: Bapi's, Recording, LSMW etc but nothing seems to be working. Please let me know how to upload the email address of the vendor.
Regards
Ritesh
goto LSMW recording method, when you enter the vendor number in the same screen you have check box like ---> Use central address management once tick this check box then only you find the email field in next screen...
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Dear,
Solved the problem. Below is a sample code.
REPORT z_vendor_email_upload LINE-SIZE 170.
PARAMETERS: obj_id LIKE bapi4001_1-objkey DEFAULT '0000101625'.
PARAMETERS: e_mail LIKE bapiadsmtp-e_mail.
DATA: iad1vl TYPE bapiad1vl OCCURS 0 WITH HEADER LINE.
DATA: iadsmtp TYPE bapiadsmtp OCCURS 0 WITH HEADER LINE.
DATA: ret TYPE bapiret2 OCCURS 0 WITH HEADER LINE.
DATA: adrnr LIKE bapi4001_1-addr_no.
START-OF-SELECTION.
IF e_mail CA '@'.
REFRESH iad1vl. CLEAR iad1vl.
iad1vl-name = 'XYZ'.
iad1vl-name_2 = ABC'.
iad1vl-sort1 = 'XZ'.
iad1vl-country = 'SG'.
iad1vl-langu = 'EN'.
APPEND iad1vl. CLEAR iad1vl.
REFRESH iadsmtp. CLEAR iadsmtp.
iadsmtp-e_mail = e_mail.
APPEND iadsmtp. CLEAR iadsmtp.
REFRESH ret. CLEAR ret.
CALL FUNCTION 'BAPI_ADDRESSORG_SAVEREPLICA'
EXPORTING
obj_type = 'LFA1'
obj_id = obj_id
OBJ_ID_EXT = ' '
context = '0001'
IV_CHECK_ADDRESS = 'X'
IV_TIME_DEPENDENT_COMM_DATA = ' '
IMPORTING
return = ret
address_number = adrnr
TABLES
bapiad1vl = iad1vl
BAPIADTEL =
BAPIADFAX =
BAPIADTTX =
BAPIADTLX =
bapiadsmtp = iadsmtp.
BAPIADRML =
BAPIADX400 =
BAPIADRFC =
BAPIADPRT =
BAPIADSSF =
BAPIADURI =
BAPIADPAG =
BAPIAD_REM =
BAPICOMREM =
BAPIADUSE =
IF ret-type NE 'E'.
CALL FUNCTION 'BAPI_TRANSACTION_COMMIT'
EXPORTING
wait = 'X'.
IF sy-subrc = 0.
WRITE: /'Email Updated'.
ENDIF.
ELSE.
WRITE: / ret-type, ret-message, ret-message_v1, ret-message_v2.
ENDIF.
ELSE.
WRITE: /'Check Email Address. It is not correct'.
ENDIF.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
I tried BDC and CATT, there was no problem.
the mail field has some limits:
1. length 241 (wether your data filled with space?)
2. must be a email format
I guess you should give more detail info so that we can solve it.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
93 | |
8 | |
7 | |
6 | |
5 | |
5 | |
5 | |
4 | |
4 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.