cancel
Showing results for 
Search instead for 
Did you mean: 

How do I pass the work environment change number to an RFC function module?

matthias_maisch
Explorer
0 Kudos
220

In my function module, which is configured in ".../aux-files/api_definitions.txt" I want to create a material revision for a document which is selected in the object manager.

Document keys etc. are passed to my z-function-module, but how do I properly access the change number of the work environment?

I assume one option is to call /DSCSAG/PLM_WUI_WENV_GET instead of passing it to the function module. Is this the only option?

Thanks,

Matthias

Accepted Solutions (1)

Accepted Solutions (1)

se_kie
Advisor
Advisor

See configuration guide of ECTR in chapter "XML File with Module Call Definitions":

getecm - "none", "active", or "document" Change number determination.


Example:

     <function apiname="/DSCSAG/MAT_BOM_RFC_CHANGE" name="MATBOM_CHANGE2" refresh="true" transaction="bright" type="material" getecm="active" >
        <import>
            <parameter name="CAD_FLAG" string="X"/>
            <parameter name="ITEM_DATA_SET" string=" "/>
            <parameter name="IV_CLIENT_VERSION" string="4050"/>
            <structure name="MATERIAL_HEADER_DATA">
                  <parameter name="TCODE" vstring="CS02"/>
                  <parameter name="AENNR" value="CHANGENUMBER_INT"/>
                  <parameter name="CADKZ" string="X"/>
                  <parameter name="MATNR" value="MATERIALNUMBER_EXT"/>
                  <parameter name="STLAL" string="01"/>
                  <parameter name="STLAN" string="1"/>
            </structure>
        </import>
        <tables/>
    </function>
matthias_maisch
Explorer
0 Kudos

Thank you. I didn't remember that section anymore. Worked perfectly for me.

Answers (0)