Roderick
03-15-2011, 08:46 AM
I'm using Word 2007 in Vista Premium. I have a template with macros and the coding is password protected.
I want to use two ActiveX check boxes in the body of the document so that when the template is run and the new document is completed there is a pair of simple Yes/No checkboxes asking the user for some information. The default is the NO check box with its .Value set to True within its properties.
Both check boxes have the same group name set within each of their properties.
I've got the following code located within the ThisDocument Object in the VBE project:
==================================
Sub chkNo_Click()
With ThisDocument
If .chkNo Then
.chkYes = False
End If
End With
End Sub
Sub chkYes_Click()
With ThisDocument
If .chkYes Then
.chkNo = False
End If
End With
End Sub
=============================
When I run the template the check boxes do not respond to the commands to select each other checked or unchecked. They act completely independent of each other ignoring that the group name is the same.
Can anyone point me where I'm going wrong, please?
Thanks. Roderick
I want to use two ActiveX check boxes in the body of the document so that when the template is run and the new document is completed there is a pair of simple Yes/No checkboxes asking the user for some information. The default is the NO check box with its .Value set to True within its properties.
Both check boxes have the same group name set within each of their properties.
I've got the following code located within the ThisDocument Object in the VBE project:
==================================
Sub chkNo_Click()
With ThisDocument
If .chkNo Then
.chkYes = False
End If
End With
End Sub
Sub chkYes_Click()
With ThisDocument
If .chkYes Then
.chkNo = False
End If
End With
End Sub
=============================
When I run the template the check boxes do not respond to the commands to select each other checked or unchecked. They act completely independent of each other ignoring that the group name is the same.
Can anyone point me where I'm going wrong, please?
Thanks. Roderick