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: 

ME_PROCESS_PO_CUST method PROCESS_HEADER to reset release status of doc

Former Member
0 Kudos

Hi Everyone,

I have read lots of threads regarding the implementation of BAdI ME_PROCESS_PO_CUST. However, I could not find one which fits our requirement which is the resetting/ restart of the release status of a PO whenever a released/approved PO has been changed not only in the quantity field but also in the other details of the document.

I believe that the method to be used in this sense is the PROCESS_HEADER. Would you know any logic which could help me restart an already released PO document whenever any changes have been made to the document?

Kindly send your recommendations.

Thanks and regards,

Reymar

1 ACCEPTED SOLUTION

former_member262988
Active Contributor
0 Kudos

Hi,

Use GET_DATA and SET_DATA methods ..in the method PROCESS_HEADER....

call method IM_HEADER->get_data
             receiving
               re_data = data.


call method IM_HEADER->set_data
             receiving
               re_data = data.

Thanks,

Shailaja Ainala.

7 REPLIES 7

former_member262988
Active Contributor
0 Kudos

Hi,

Use GET_DATA and SET_DATA methods ..in the method PROCESS_HEADER....

call method IM_HEADER->get_data
             receiving
               re_data = data.


call method IM_HEADER->set_data
             receiving
               re_data = data.

Thanks,

Shailaja Ainala.

0 Kudos

Hello Shailaja Ainala,

Would you know the values of some fields which will tell me if the document is partially released, fully released, or 'to be released' after getting the data from the header part of the document? What are the useful fields and their values for me to identify the release status of the document?

Thank you very much!

Regards,

RE

former_member262988
Active Contributor
0 Kudos

Hi,

check out the field FRGKE and FRGZU ....in RE_DATA.....which you wil get from get_data...

Thanks,

Shailaja Ainala.

0 Kudos

Thanks Shailaja Ainala.

Additional question: If I now have a new value (controlled value) on fields FRGKE and FRGZU, how could I set these values as the new values for the mentioned fields? There is no exporting or changing parameter in the method PROCESS_HEADER. Could I just set them as FRGKE = var1 and FRGZU = var2?

I hope you could guide me on this.

Thank you!

RE

0 Kudos

Hi,

There is method set_data ..use that ..

Thanks,

Shailaja Ainala.

0 Kudos

Hi,

I used this code:


CALL METHOD im_header->get_data
RECEIVING
re_data =  lmpoheader.

IF lmpoheader-frgke = 1 AND
    lmpoheader-frgzu IS NOT INITIAL.

lmpoheader-frgke = 2.
lmpoheader-frgzu = ''.

CALL METHOD im_header->set_data
EXPORTING
im_data = lmpoheader.

ENDIF.

After saving the PO document, the fields FRGKE and FRGZU were not changed. When I debugged the code, the values of the fields were changed. I just don't know if the last CALL METHOD has been properly executed so that IM_DATA may contain the changed values.

Thank you and regards,

RE

Edited by: Reymar Ellazo on Apr 21, 2009 6:19 PM

Former Member
0 Kudos

As far as I can still remember, the field values of FRGKE and FRGZU were updated in this Process_Header method using a Field Symbol operation. thanks.