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: 

problem in updating Data for infotype P0009 through BADI

Former Member
0 Kudos

Hi,

we are facing a problem while trying to update value of Date field for infotype P0009 through PA30.

we have tried to update by using BADI hrpad00infty, we are providing value in new_innnn structure of method

AFTER_INPUT, but the value is not getting updated for that PARNR.

Can anyone help me regarding the same?

4 REPLIES 4

former_member209703
Active Contributor
0 Kudos

Hi

HRPAD00INFTY BADI methods don't allow to modify any values of the current record being processed, but there's a possible wworkaround accessing memory fields using field-symbols:


method IF_EX_HRPAD00INFTY~AFTER_INPUT.
  
  FIELD-SYMBOLS: <fs> type p0009.
  
  assign ('(MP000900)P0009') TO <FS>.
if sy-subrc eq 0.  
  <FS>-YOURFIELD = YOUR_VALUE.
endif.
  
endmethod.

0 Kudos

Hi,

I have alreday tried with the same, but it did not work. It is not reflacted when returning back to the TCode screen.

Actually i am trying to change the ENDDA field.

0 Kudos

OK if your are modifying ENDDA, then use this.


  FIELD-SYMBOLS <fs> type PRELP.
  assign ('(MP000900)CPREL') TO <FS>.
  IF SY-SUBRC EQ 0.

    <FS>-ENDDA = '20110119'.

    ENDIF.

0 Kudos

Hi,

Its' works while trying through SAP , i need to do it via ESS. I have created my own enhancement implementation for BADi HRPAD00INFTYBL, BADI have been implemented for HRPAD00INFTYDB.

If we go thorugh teh call stack while triggering through the SAP itself then the above code works as the FS can be assigned,

But in case of triggering it via protal , it can not be assigned as ('(MP000900)CPREL') is unknown.

Canyou please provide any feedback for this scenario.