Quantcast
Channel: CSLA .NET
Viewing all articles
Browse latest Browse all 764

Firing of calculation business rules

$
0
0

Hi,

I am using CSLA and silverlight in my project. I am using the calculation business rules. There is a situation that one calculation rule has to be applied on one or more properties (which is already been set by another calculation rule). In the UI, both are shown in Label and cannot be directly edited. Although, one of the Labels changes when the first rule fires, but this change doesn't fire the second rule (which is dependent on the value of first label) and the value of the second Label is not affected. However, when we save the page, and when the page reloads again, then the calculation fire and set the value of that property.

For example:

Rule1_ChangingLabel1(prop1, prop2, targetprop)

--> When there is a change in prop1 or prop2, this calculates the 'targetprop' (in Label).

When the value of 'targetprop' changes by the above rule, the second rule below should fire.

Rule2_ChangingLabel2(targetprop, prop3, prop4)



But the second rule doesn't fire when the 'targetprop' changes.


Could this be because it is in a Label? I would be thankful if anyone could let me know some solution.

Regards,

Vikas


Viewing all articles
Browse latest Browse all 764

Trending Articles