Checkboxes affecting other controls



I have a main form containing 2 checkboxes, ChckIBCCP and
ChckOtherReferral

The respective checkboxes when checked cause the SpecialEffect
Property to make ALL the textboxes to appear Shadowed.

The specific Textboxes and specific Combo Boxes required to appear
Shadowed
are ALMOST the same in number regardless which checkbox is checked.

However, there is one Textbox on the main form that must appear Flat
when ChckIBCCP is
checked, but must appear Shadowed when ChckOtherReferral is checked.

AND However, there are three Textboxes and two Combo Boxes on the main
form that must appear Flat when ChckOtherReferral is checked, but must
appear Shadowed when ChckIBCCP is checked.

1)How how do I cause individual textboxes to appear Flat?

2)How do I cause the Textboxes and Combo Boxes to highlight upon
checking the respective checkbox?

Thanks,

John

Here is my code:


Private Sub ChckIBCCP_Click()
Dim ctl As Control


For Each ctl In Me.Controls
If ctl.Tag = "Shadow1" And ChckIBCCP = True _
And ctl.ControlType = 109 Then
ctl.SpecialEffect = 4
ElseIf ctl.Tag <> "Shadow1" And ctl.ControlType _
= acTextBox Then
ctl.SpecialEffect = 1
End If
Next
End Sub


Private Sub ChckOtherReferral_Click()
Dim ctl As Control


For Each ctl In Me.Controls
If ctl.Tag = "Shadow1" And ChckOtherReferral = True _
And ctl.ControlType = 109 Then
ctl.SpecialEffect = 4
ElseIf ctl.Tag <> "Shadow1" And ctl.ControlType _
= acTextBox Then
ctl.SpecialEffect = 1
End If
Next


End Sub
.



Relevant Pages

  • Re: Is there something better than ActiveX textboxes?
    ... I would recommend using instead checkboxes, textboxes and dropdown listboxes ... FormField object in the document. ... Do the ActiveX controls lead to broken ...
    (microsoft.public.word.vba.general)
  • Re: Checkboxes and Shadowing, Unshadowing, Highlighting
    ... The respective checkboxes when checked cause the SepcialEffect ... 1)Although the Textboxes and Combo Boxes required to appear Shadowed ... Private Sub ChckIBCCP_Click ... Dim ctl As Control ...
    (comp.databases.ms-access)
  • Dataset
    ... parts data from the dropdown lists, textboxes, radiobuttons, and checkboxes ...
    (microsoft.public.data.oledb)
  • shorter question ref. simple code
    ... fills out textboxes and checkboxes while the program places the values ... from the text and checkboxes into a .csv file. ... items in random order, you want to go through them in a specific ...
    (comp.lang.perl.misc)
  • Checkboxes and Shadowing, Unshadowing, Highlighting
    ... The respective checkboxes when checked cause the SepcialEffect ... 1)Although the Textboxes and Combo Boxes required to appear Shadowed ... Dim ctl As Control ... Private Sub ChckOtherReferral_Click ...
    (comp.databases.ms-access)