Application Development 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: 

ORDERS01 Populating customer e-mail field in sales order E1EDKA1

Former Member
0 Kudos
1,117

Hi,

I can create orders using Inbound IDOC ORDERS01 and populate address data using E1EDKA1 with PARVW "WE" for ship to party.

In the sales order under communication there is an e-mail field (field name) SMTP_ADDR

Is it possible to populate into this field from the IDOC.

Also under further attributes there is a VAT RegNo field (field anme STCEG), I would like to do the same thing with that field.

Anybody got any suggestions?

Thanks

Rob

2 REPLIES 2

Former Member
0 Kudos
250

hI,

Please check IDoc Reduction (BD53) or Segment Filters (BD56) whether segment E1EDP05 was applied or not.IF not debugg the standard program RSNAST00 to debug the FM IDOC_OUTPUT_ORDERS.

Please specify the output application 'V2', enter the object key with delivery number (i.e. 0080000325) which correspond with the IDoc and check the send again checkbox.

Enter '/h' at command center and execute the above program.

Then go to menu -> Breakpoints -> Breakpoints at -> Function module -> IDOC_OUTPUT_ORDERS -> Continue -> Click on 'Run' (F8) -> ....

*Reward points

Regards

Former Member
0 Kudos
250

Hi

Use the User ID of the IDCO (BNAME) field and fetch the Address number from USR21 and from that address number fetch the Mail id from ADR6 table and populate the IDOC like

lv_usrid = gv_ernam.(BNAME)

SELECT SINGLE persnumber addrnumber FROM usr21

INTO (lv_pernr,lv_adrnr)

WHERE bname = lv_usrid.

IF sy-subrc = 0.

SELECT SINGLE smtp_addr INTO lv_mail FROM adr6

WHERE addrnumber = lv_adrnr AND

persnumber = lv_pernr.

ENDIF.

Take the Sales Doc no and the Partner function from the segment E1EDKA1

and pass to VBPA table and fetch the STCEG atbale and populate the same.

Reward points if useful

Regards

Anji