Enabling checkbox when checked

  • Thread starter Thread starter RTT
  • Start date Start date
R

RTT

In my form I have a checkbox Checkbox1. this is not checked.
Now a want to program in VB that if the checkbox is checked it becomes
enabled. i tried:

if CheckBox1.checked = 1 then
checkbox1.enabled = 0
enf if

but he says he can't find object CheckBox1 wich is on my form.. anyone
who can help me?
 
thxs for your help Sue. I'm just not there yet.

now i have this:
Sub Item_Open()
Set myinspector = Item.GetInspector
Set myPage1 = myInspector.ModifiedFormPages("Message")
Set check = myPage1.Controls("chkNeedCheck")
If check.value = 1 Then check.visible = 0
End Sub

so when the forms opens it checks if the value of checkbox chkNeedCheck
is checked, if it is it should be invisible. when it is not checked,
you can still check and uncheck it until you open it again or send it
to someone else, he want see it anymore...

but it's still not working, when i open it checked if stays visible...

anyone who has an idea?
 
Did you publish the form? Code doesn't run on unpublished forms.

--
Sue Mosher, Outlook MVP
Author of Configuring Microsoft Outlook 2003

and Microsoft Outlook Programming - Jumpstart for
Administrators, Power Users, and Developers
 
Back
Top