deactivate macro or LostFocus
Thanks Norman,
I'm a beginer with VBA and don't understand your example:
CheckBox1 - what does this represent?
Yourcode - I presume this means the macro I copied into Code.
Does this mean that after my code runs, the last line will now be
*CheckBox1.Enabled = False*?
I'd like my trigger to be one of two methods:
1. A fourth Option Button called "Lock" which, when run, would deactive the
other three Option Buttons, or
2. When text is typed into a certain cell, it would deactivate the three
Option Buttons.
Thanks if you can help me see how to fit your code into this scenario.
Harold
====================
Hi Harold,
Try something like:
'=============
Private Sub CheckBox1_Click()
'Yourcode
CheckBox1.Enabled = False
End Sub
'<<=============
---
Regards,
Norman
"Harold Good" wrote in message
...
Hi, I don't know VBA but I recorded and copied three macros into code and
they are activated by three ActiveX Option Buttons. The buttons allow the
user to chose the type of project for which they will be entering data.
But once they choose the type, I'd like to use a trigger event to
deactive the code so they can no longer click on an Option Button and
thus loose their data.
How is the best way to do this? Hopefully there is a simple way to have
the Option Buttons gray out and lose focus so they can't be clicked
anymore. It should be all or nothing, all three are active or all three
are inactive, never a combination of some on and some off.
Can someone point me in the right direction?
If it requires a bit of code, could you please help me with that?
Many thanks,
Harold
|