11-01-2007 5:48 PM
I need to add a custom segment to the BATMAS IDOC for the batch short text. I created a new basic message type ZBATMAS with a new segment and am now stuck.
How do I get the BAPI to use the custom message type so I can fill in the new segment from a user exit? Can this be done with a BAPI IDOC? Is there a better way?
Any help is very much appreciated!
Thanks,
Chuck
08-12-2008 12:54 AM
Finally got it figured out. Steps I used to generate the new customer BAPI-IDOC interface:
1. Created custom structure with data elements desired
2. Copied the BAPI_BATCH_REPLICATE and BAPI_BATCH_SAVE_REPLICA function modules to custom function modules
3. Add parameter for custom segment to BAPI_BATCH_SAVE_REPLICA
4. Extend BAPI object with custom segment
5. Generate the ALE interface (this was where I got stuck originally)
6. Assign function module to generate message type (BD60)
7. Assigned additional change pointer field to message type (BD52)
11-10-2010 5:23 PM
Hi Charles,
What transaction is used for step 4 (Extend Bapi with custom segment) ?
Thanks!
04-26-2012 3:17 AM
Hi Charles,
If you dont mind, can you email me your custom function module code , if you have it with you or just tell me what is the difference between the 2 function modules and why do we need to copy 2 function modules instead of having one.
Please dont mind, as i am having same requirement i am asking this.
my mail id is janagarsundaramoorthy@gmail.com
Regards
S.Janagar
05-01-2021 6:19 PM
as it is generated IDOC , can’t extend BATMAS . Instead create a copy of message type and IDOC . Populate IDOC on event save .