cancel
Showing results for 
Search instead for 
Did you mean: 

Value 0 calculated by macro

Former Member
0 Kudos

Dear experts,

I am trying to create a macro that simulates the behaviour of the standar macro "Days' Suply". I calculate a "fake" Stock on hand proyected and calculate the days' supply by calling the standar function COVER_CALC.

Everything works propperly with an exception. I am not able to calculate 0 value.

When the result of the calculation is 0, this does not overwrite the previous value of the resultant KF.

I have tried by setting to 0 the result KF as a first step in the macro with no sucessfull result.

Does anybody now any rule to follow in this case? Should I have another previous macro to initialize the value?

What Can I do?

Thanks a lot,

Accepted Solutions (0)

Answers (1)

Answers (1)

Former Member
0 Kudos

I have been able to solve te issue by unmarking the flag "Do not diplay Init Values" that appears in the definition on the macro.

I do not understand this very well because mentioned flag is mark in the stander macro "Days' Supply", but it worked.

If anybody has any comment I will apreciate.

Thanks!!

Former Member
0 Kudos

when you add the object for row you can see flag on a field called Retain existing values

Indicator - Showing Whether Existing Values Will Be Overwrittn

The system writes macro results only to cells without existing values.

it needs to be Overwrite Existing values-

The system writes macros results to all cells; if a cell already contains a value, this value is overwritten with the macro result.

Former Member
0 Kudos

I had this flag already marked, so I guess that was not the issue. But thanks anyway.

Regards,

Susana