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: 

Trigger Item Category determination in sales order via program

Former Member
0 Kudos

Hi,

We are changing item category through an exit based on a field at item level, which the user would enter manually.

However once the exit changes the item category, if the user reverses his selection or gives another value for which item category should be the orginal one, i need to change the item category back to what was originally determined.

Rather than looking up the config tables of item category determination, we would like to trigger item category determination through the exit itself.

Can someone suggest if this is possible, if so what is the code to be written.

Regards,

KC

SAP SD

1 ACCEPTED SOLUTION

Former Member
0 Kudos

I think you can use FM 'RV_VBAP_PSTYV_DETERMINE'

make sure you pass correct values in parameters like :

t184_auart = vbak-auart

t184_mtpos = mvke-mtpos

t184_uepst = uepst " item category if high-level item if it's a BOM

btw, as there are a lot of things which are dependent on item category - make sure you redetermine it in the right place.

3 REPLIES 3

Former Member
0 Kudos

I think you can use FM 'RV_VBAP_PSTYV_DETERMINE'

make sure you pass correct values in parameters like :

t184_auart = vbak-auart

t184_mtpos = mvke-mtpos

t184_uepst = uepst " item category if high-level item if it's a BOM

btw, as there are a lot of things which are dependent on item category - make sure you redetermine it in the right place.

0 Kudos

Hi Siarhei,

I guess this is what we are looking for. This would serve our purpose.

Thanks,

KC

Former Member
0 Kudos

Hi,

You can use the following user exit to change the item category in the include MV45AFZB..

&----


*& Form USEREXIT_SOURCE_DETERMINATION

&----


<b>* This Userexit is used to add additional logic for finding *

  • the source of the plant or the item category.</b> *

  • *

  • This form is called from form VBAP_FUELLEN *

  • *

----


FORM userexit_source_determination.

Thanks,

Naren