Skip to Content
0
Former Member
Oct 24, 2007 at 10:57 PM

Lockout macro based on a KF

9 Views

I'm new to SAP macros, and am looking for some assistance.

I need to lockout (make uneditable) cells X and Y when the locking KF is set to any value > 0.

I've figured out how to write the macro to work for for 1 period, but I'm not able to figure out how to do it for the future.

Example:

................[P1]..[P2]..[P3]

Row X....... LO .. LO ..Open

Row Y ...... LO .. LO ..Open

Lock KF ... 1 ..... 1

I've come up with the following:

Step : (65 iterations: P11/2007; P10/2012)

If

Cell: Lock KF (P12/2007)

> 0

Cell: Row X (P12/2007) =

Cell_Input( 0 )

Cell: Row Y (P12/2007) =

Cell_Input( 0 )

How do I make the same macro work for each period going into the future without having to write a separate macro for every period??