Checkbox

M

Moody

Hello, i am trying to check a checkbox with the click action of a command
button but i can seem to be able to do this.

i have entered

Me.[checkbox] = Yes

but this unchecks a checked box but does not check a unchecked box, i want
to achieve the opposite. i know i am missing something simple. can someone
help me.

thank you
 
K

Klatuu

Me.[checkbox] = Not Me.[checkbox]
If it is True it will change to False
If it is False it will change to True
 
M

Moody

Thank you, thats great !

Sandra Daigle said:
Try this:

me.checkbox=true

--
Sandra Daigle [Microsoft Access MVP]
Please post all replies to the newsgroup.

Hello, i am trying to check a checkbox with the click action of a
command button but i can seem to be able to do this.

i have entered

Me.[checkbox] = Yes

but this unchecks a checked box but does not check a unchecked box, i
want to achieve the opposite. i know i am missing something simple.
can someone help me.

thank you
 
M

Moody

Thanks for the response, really appreciate your help, thank you

Klatuu said:
Me.[checkbox] = Not Me.[checkbox]
If it is True it will change to False
If it is False it will change to True

Moody said:
Hello, i am trying to check a checkbox with the click action of a command
button but i can seem to be able to do this.

i have entered

Me.[checkbox] = Yes

but this unchecks a checked box but does not check a unchecked box, i want
to achieve the opposite. i know i am missing something simple. can someone
help me.

thank you
 
Top