vba - Excel tickbox and lock the cell -
dears, need code following: when tick checkbox should freeze not possible edit it, long password typed in.
the checkbox connected cell , below macro assigned this: perhaps added existing macro?
thank you
sub checkbox_date_stamp() dim cbx checkbox 'application.caller returns name of checkbox called macro set cbx = activesheet.checkboxes(application.caller) '.topleftcell returns cell address located @ top left corner of cbx checkbox cbx.topleftcell 'check checkbox status (checked or unchecked) if cbx.value = xlon ' checkbox checked ' user name , date-time .offset(0, 1).value = environ("username") .offset(0, 2).value = else ' checkbox unchecked; clear cell contents? .offset(0, 1).clearcontents .offset(0, 2).clearcontents end if end
Comments
Post a Comment