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: 

va41 : Enhancement : In conditions tab pricing elements amount has to be fetched automatically

Former Member
0 Kudos
156

Hai Guru's. Trust every one is doing good. I have a requirement where in VA41 basing on Document type amount in conditions tab pricing elements has to be fetched automatically and it should be in non modifiable mode. I tried exit MV45AFZZ but KOMV-KBETR this field is clearing. SELECT * FROM ZMARKET_PRICE INTO corresponding fields of table IT_PRICE    WHERE BUDAT    = SY-DATUM        and  COMMODITY = 'SUGAR' . LOOP AT IT_PRICE.  IF VBAK-AUART = 'ZKSA'.  KOMV-KBETR = IT_PRICE-KSLNP. ENDIF. endloop. I tried exit MV45AFZZ and added the logic mentioned  above but KOMV-KBETR this field is clearing. Please help me. Regards, Prudhvi Choudary.

5 REPLIES 5

Former Member
0 Kudos
63

Prudhvi,

Please look into VOFM routines like Condition Value and Condition base value.

Thanks,

VM.

narendar_naidu
Active Participant
0 Kudos
63

Hi,

As venkat mentioned, VOFM routines can be used specifically for pricing calculations,display and modifications.

Implement using Condition base value and condition value formulas.

regards,

former_member215424
Active Participant
0 Kudos
63

Hi ,

Please check whether the code that  you have added is at the right place in the exit. It might so happen that the value you are trying to populate is getting overwritten or getting cleared some time later in the processing after executing your code.

Otherwise as suggested above, you can create a custom routine(copy of original with additional changes of your requirement )  in VOFM and try to assign it to conditions tab value with the help of your functional.

Regards,

Shruti

0 Kudos
63

Thanks for your reply. While debugging value is present in KOMV-KBETR this field. But in output it is not showing. As you said I am trying VOFM. In VOFM which is the correct Group amoung 63 group classes for conditions-- amount.

0 Kudos
63

Hi Prudvi,

THis is a PDF which will help you solve your issue , please go through it.

http://saptechsolutions.com/pdf/VOFMFormulaRoutines.pdf

regards,