View Single Post
 
Old 01-13-2022, 03:10 PM
Guessed's Avatar
Guessed Guessed is offline Windows 10 Office 2016
Expert
 
Join Date: Mar 2010
Location: Canberra/Melbourne Australia
Posts: 4,176
Guessed has a brilliant futureGuessed has a brilliant futureGuessed has a brilliant futureGuessed has a brilliant futureGuessed has a brilliant futureGuessed has a brilliant futureGuessed has a brilliant futureGuessed has a brilliant futureGuessed has a brilliant futureGuessed has a brilliant futureGuessed has a brilliant future
Default

Checkboxes don't typically have a name that begins txt. Are you sure it is a checkbox and not a textbox?

The type of the userform textbox and the variable must match with the code you are using. If one is a string and the other is a boolean then you will need to convert it.
For example, does ActiveDocument.Variables("plaintiff").Value return "True" or True? These are different - one is a string and one is a boolean. Can document variables hold anything other than strings?

Perhaps try to initialize the value with
Code:
Me.txtPlaintiff.Value = ActiveDocument.Variables("plaintiff").Value = "True"
__________________
Andrew Lockton
Chrysalis Design, Melbourne Australia
Reply With Quote