excel - Disable checkboxes when sheet opened in vba -


i have 3 checkboxes. when user opened sheet, he/she must not check checkboxes. want them disabled. how can that?

not sure if meant activex or formcontrol, here go

code

private sub worksheet_activate()   dim myactivex object   set myactivex = sheet1.oleobjects("checkbox1")   myactivex.object.value = true   myactivex.object.locked = false ' make false if wish enable   myactivex.object.enabled = false ' option disable    dim myformcontrol checkbox   set myformcontrol = activesheet.shapes("check box 1").oleformat.object   myformcontrol.value = true   myformcontrol.enabled = false ' make true if wish enable end sub 

live gif demo enter image description here


Comments

Popular posts from this blog

html - How to custom Bootstrap grid height? -

javascript - pass values from mssql to views in node -

ruby - unknown property method: 'wait' on EC2 windows server Instance -