How to protect option button?

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Good day everybody,

I have an entry form created using Excel XP. There are two sections in this
form.
User 1 will fill the first section and protect the worksheet which will
protected the 1st section from being changed. This form will be send to User
2 to fill the second section.
However, the option buttons in 1st section are still able to be click and
thus option is changed.
How do I protect the option button from being changed?
I was told it can't be done and have to use VBA. Can anyone guide me how to?

Thank you in advance and have a nice day.

Best regards,
Julie
 
If linked to a cell, if both the cell and the control are locked and the
sheet and objects are protected (3 options under worksheet protection), then
it should resist being clicked on.
 
Hi Tom,

Thank you for your response. I have try it. The link cell will not change
value and message will said the cell you are trying to change is protected.

This will not change link cell value, but however, the option button will
change.
Now the option button and the link cell are not in line. This will create
problem for me to know which is the right result.

Do you have any clue how to solve this?

Hope to hear from you again.

Best regards,
Julie
 
Your correct - that is the behavior in Excel 2003. It is not the behavior
in Excel 97. These are the two versions I tested. So I suspect not.
However, as to the correct value, obviously it is what is shown in the cell
as, as you have said, it doesn't change.
 
Julie,

One way, assuming that you have another option button that counters the
effect is to add a macro to the buttons,, something like

Sub OBLinks()
Dim sLink As String
Dim oButton As Object

sLink = ActiveSheet.OptionButtons(Application.Caller).LinkedCell
With ActiveSheet
Set oButton = .OptionButtons(Range(sLink).Value)
If .ProtectContents Then
oButton.Value = True
End If

End With

End Sub

--

HTH

RP
(remove nothere from the email address if mailing direct)
 

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

Back
Top