cancel
Showing results for 
Search instead for 
Did you mean: 

Formula Only works when click Update Pricing

Former Member
0 Kudos

I've created a condition formula that changes KOMK-TXJCD. It only works when I click Updat on the condition screen. But just saving does not use the new TXJCD that I assigned from the plant in the alternate formula. In debug I see the values changing. Here is a copy of the code.

Any help MUCH rewarded.

Data lv_titlepass(1) type c.

DATA wa_plant_txjcd like t001w-txjcd .

  • start by assuming default .

lv_titlepass = 'D' .

  • now look at incoterm field

CASE KOMP-OITITLE.

WHEN '1'.

lv_titlepass = 'D'.

WHEN OTHERS.

lv_titlepass = 'O'.

ENDCASE.

  • the default is tax is charged using destination txjcd.

  • If 'O' then change TXJCD

  • use the plant

If lv_titlepass = 'O' .

clear wa_plant_txjcd .

select single txjcd from t001w into wa_plant_txjcd

where werks = komp-werks .

If sy-subrc <> 0 .

exit .

else.

KOMK-txjcd = wa_plant_txjcd .

endif .

Endif .

Accepted Solutions (0)

Answers (2)

Answers (2)

Former Member
0 Kudos

using another method

Former Member
0 Kudos

in copying control set Pricing type "B" (Carry out new pricing)

for your item category

Former Member
0 Kudos

any clues on where in the formula i would do this. Thanks

Former Member
0 Kudos

it depends on what document you are creating - do you do invice for your order?

Former Member
0 Kudos

My question is there a way to do i the code.

Sales order and then invoice

Former Member
0 Kudos

in this case run VTFA

select your source (sales order) and target (billing type)

goto item

select your item category

goto details

set Pricing type "B"

Former Member
0 Kudos

My item category is not listed.

Former Member
0 Kudos

you need to add

use the same transaction - you can do it by copying from existing itca (for example take TAN)