cancel
Showing results for 
Search instead for 
Did you mean: 

multiply 2 field in an add screen set

Former Member
0 Kudos

Hi (again ),

I have to show a field with the result of the multiplication of other two fields:

Field A : amount (decimal field) value added by user;

Field B : Price (decimal field determinated by Update Rule that returns a numeric field from a complex table);

Field C : Total price (decimal determinated by Update Rule (screen 1);

Screen 1

Example:

Field A : 10

Field B : 6,57

Expected Value on Field C : 65,7

I almost figured out how to do this, but the field C is not always refreshed when I change Field A or B value.

Accepted Solutions (0)

Answers (3)

Answers (3)

mark_pe
Active Contributor
0 Kudos

Giacomo,

Hi.  How did you setup your Field C for your Transaction Property that uses this Update rule?

You have a Transaction1 that points to ScreenSet1 that your update rule is using.  That Transaction1 has properties for your Field C.

Is the Transaction -> Properties -> Field C  setup for Initial Value : Rule - Before Data Entry or Rule - After Data Entry or something else?

Regards,

Mark Pe
SAP Platinum Support Engineer

Former Member
0 Kudos

I need that value has a live update every time I change field A&B.

Former Member
0 Kudos

Instead of taking the value from screenset property, i would suggest to use SCREENFIELDVALUE function and pass the field name.

Example: PROD

                    SCREENFIELDVALUE

                         Name of the field(FieldA)

                    SCREENFIELDVALUE

                         Name of the field(FieldB)

Former Member
0 Kudos

I ran some test with this rule, but it does not working.

bill_froelich
Product and Topic Expert
Product and Topic Expert
0 Kudos

When using SCREENFIELDVALUE you have to specify the name of the field from the editor not the property reference.  Create a constant string with the field name as a parameter to SCREENFIELDVALUE.

--Bill

Former Member
0 Kudos

It is not working anyway.

Former Member
0 Kudos

Using the ATE in the editor, can you debug the rule with the setting set to Low detail, and post the output here so we can see what is being called?

Former Member
0 Kudos

Thanks for this advice ---> "set to Low detail" . I did not know how to debug correctly  the rule before you told me.



So from the debug I figured out that I try to get the screen field value from a field with an update rule. So I just copy that rule in my field C and now it is working.

bill_froelich
Product and Topic Expert
Product and Topic Expert
0 Kudos

What client are you trying to use?  Have you tested in the ATE that is part of the Editor and turned on rule debugging to see if the rule is firing and what values it is finding?

--Bill