Trigger MATMAS IDoc using BTE Function

Trigger MATMAS IDoc using BTE Function: this is a sample ABAP Program to generate a MATMAS IDoc for a Material Change using BTE event when a SAP Material is saved in MM02 / MM01.

Trigger MATMAS IDoc using BTE Function ABAP

First Step is to generate IDoc Control Record : EDIDC
The Second Step is to generate IDOC Data Table : EDIDD
The last step is to call the MASTER_IDOC_DISTRIBUTE to generate the IDoc

This sample ABAP function code is a little particular to generate MATMAS IDoc using BTE Function ABAP. This is a enhanced copy of the standard Function SAMPLE_INTERFACE_00001250.

Find more resource about the Most important Idocs Tcodes and Idocs Tables and also .

The second step is to fill some Data into MATMAS Idoc such

  • E1MAKTM : MAKT : Material Description Table
  • E1MARCM : MARC : Material Plant Data
  • E1MARDM : MARD : Material Storage Location Data
  • E1MARMM : MARM : Material Alternative Unit Table
  • E1MLANM : MLAN : Tax Classification for Material

The Last step is to generate the IDoc as following using MASTER_IDOC_DISTRIBUTE BAPI

Here it is the Idoc MATMAS should be created when a material is Saved ( if the ALE configuration is already set-up)

SAP and SAP logo are registered trademarks of SAP AG. is not associated with SAP AG.
We have made every effort to make sure provide relevant search results, use the content on this site at your own risk.

We are a participant in the Amazon Services LLC Associates Program, an affiliate advertising program designed to provide a means for us to earn fees by linking to and affiliated sites.