cancel
Showing results for 
Search instead for 
Did you mean: 

The macro attempted to modify a key figure that is not locked

former_member224276
Participant
0 Kudos

Hi

In my planning area I choosen detailed lock, keyfigure specific lock and do not lock read only keyfig after that In interactive DP, I have 2 Planning Books A and B .when I load the selection for book A itu2019s loaded well because all are editable key fig but when I load book B I get error u201CThe macro attempted to modify a key figure that is not lockedu201D in this book 3are editable keyfig 3 are display. I am in SAP SCM 7.0,I had seen the SAP NOTE 851731but its too old i think now iam in advanced that that but that note is not there in my system .

Any ideas on why this is happening?

Regards

siva

Edited by: sivaram2411 on Feb 3, 2012 1:52 PM

Accepted Solutions (1)

Accepted Solutions (1)

former_member187488
Active Contributor
0 Kudos

Hello,

According to your setting in the palnning area ("do not lock read-only key figures"), if you have set a key figure as "Output Only" in /sapapo/mc8b or by a default macro, then this key figure could not get locked.

It is not allowed to make changes to unlocked key figures. So if there's a macro that tries to update this key figure, you'll get the error message.

If you have "do not lock read-only key figures" set, you must make sure that your macros do not make changes to those key figures that are output only (read only).

Best Regards,

Ada

former_member224276
Participant
0 Kudos

Hi

Thanks a lot first you gave the repley, in Planning Book B 3 are "output only" and remaining 3 keyfig are "editable".

Here my macro logic is when i change the value of "editable keyfig" this changes to the "output only" keyfig value automatically.

So in this case how can i proceed with/without "do not lock read only keyfig"

Is there any anternative solution for both are useing i mean activate "do not lock read only keyfig" in PA and use the same macro.

Regards,

siva

former_member187488
Active Contributor
0 Kudos

Hello,

Maybe you can use macro function ROW_INPUT().

In your macro, before you change the read-only KF, you set it as eidtable by using "row = ROW_INPUT(1)", then you change the KF's value, and at last set the read-only back by using "row = ROW_INPUT(0)".

Please try this

Best Regards,

Ada

former_member224276
Participant
0 Kudos

Hi,

Thanks for your help I have modified my display keyfig to editable keyfig in my PB after that through macro i have modified editable keyfig to display keyfig . Then its working fine.

regards,

siva

Answers (0)