Set a form boolean field to TRUE

I have a Base form field “ValidDL” referring to a boolean field in my table. How do I set that value with a macro?

	Me.getByName("ValidDL").text = TRUE

“Me” is the form object. What should I replace “text” with?
Thanks, David

Hello @David_Ssc,

If your field “ValidDL” is actually a Checkbox control in your form, then you could write:

Me.getByName("ValidDL").State = 1

Never thought to use an integer value to set a boolean field! Thank you. Apparently, you do not need to .commit() the change after it is set in this way.

well, Checkboxes can have an intermediate state, hence the need for a short instead of a boolean.
I think it still needs commiting, since only the state of the control was changed, not the bound field.