×

[PR]この広告は3ヶ月以上更新がないため表示されています。
ホームページを更新後24時間以内に表示されなくなります。




Sapass

 Simplify SAP R/3 development with Excel VBA/VB RFC  
Home> UserExit>MCS60001



Index

MCS60001

User Exits from SIS
Usually, data from the documents themselves are used for the statistical update from the billing documents.
If you want to use additional data for the statistical update that are not included in the documents, determine this data by using User Exits.

User Exit '001' - Enhancing data on the document header level
User Exit '002' - Enhancing data on the item level

Procedure:

1. Definition of the new data as fields in the ABAP/4 Data Dictionary
The fields must be incorporated into the User structures MCVBRKUSR (document header level) and MCVBRPUSR (item level) that are provided
for them.
2. Determining the new fields in the User-Exits
You can use the document data for determining the field contents:

User Exit '001':
I_XMCVBRK (all fields from the document header - structure MCVBRKB)
I_XMCVBUK (all fields from the document status - structure MCVBUKB)
I_CONTROL (general updating control, for example, if a normal update
or the set up are to be taken into consideration)

User Exit '002':
I_XMCVBRK (all fields from the document header - structure MCVBRKB)
I_XMCVBUK (all fields from the document status - structure MCVBUKB)
I_XMCVBRP (all fields from the document item - structure MCVBRPB)
I_XMCVBUP (all fields from the item status - structure MCVBUPB)
I_CONTROL (general updating control, for example, if a normal update or
the set up are to be taken into consideration), that is, in item processing, even the data from the document header are used. If there is more than one item in the document, the User Exit will then run more than once (for every item). When processing an item, no data is available from the other items.

After determining the new field contents, they are transferred to the update program by using the structures E_XMCVBRKUSR (User Exit '001') and E_XMCVBRPUSR (User Exit '002').

3. Field catalogs
Incorporate the new fields in the field catalog so that they can be used in the info structure definitions.

CAUTION !!!
Please note the following situations when using this User Exit:

1. Updating during document changes

When documents are changed, the application always provides the data in two ways: the document data that corresponds to the document status before the change and the document data after the change.
When using the data before the document change, the statistical update takes back the original updated statistical data (negative posting). The normal statistical update is then done with the new data.
If you want to determine additional data using User Exits, then you must ensure that in document changes this data was not changed since the last change or that the old data status can be determined. You can process the old status in the field SUPKZ in the structures. SUPKZ = '1' indicates that the old document data can be processed and SUPKZ = '2' means that the new document status is available.

2. Data that is read twice

If additional data is determined from the customer or material master records, then check whether an enhancement of the document data can be done instead. If the document data is enhanced by the additional fields necessary for the statistical update, they can then be used when reading the master data during document processing. A second determination in the statistical update is then no longer necessary. Even the problem with determining the 'old' data status (see above) is no longer valid, as the old field contents have already been stored in the document.


Function/Program:
  • EXIT_SAPLMCS6_001: SIS: User Exit for Billing Documents - Header Data
  • EXIT_SAPLMCS6_002: SIS: User Exit for Billing Documents - Item Data

02-Oct-2005