disabling cells based on cmd button

C

Consuelo

HELLO,
I AM TRYING TO FIGURE OUT HOW TO MAKE CERTAIN CELLS
DISABLED BASED ON AN CMD BUTTON'S (ON USER FORM) ONCLICK
EVENT. PLEASE HELP!
CONSUELO :)
 
R

Ron de Bruin

Nor sure if I understand you correct?
But try this

Private Sub CommandButton1_Click()
Sheets("sheet1").Unprotect
Sheets("sheet1").Range("a1:c1").Locked = True
Sheets("sheet1").Protect
End Sub
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top