*Resolved* Checkbox VBA Syntax?
I've got a simple piece of code in Excel VBA which is:
Code:
Sub CheckBox1_Click()
If CheckBox1.Value = True Then
Range("A1").Value = 1
Else
Range("A1").Value = 0
End If
End Sub
which is supposed to make 1 or 0 appear in cell A1 depending on whether or not a checkbox is ticked. However all I get is the error message 'Runtime error 424. Object required'.
I don't know what this means or why the code doesn't work and I can't find anything in Excel Help which explains what's wrong!
Anyone help?
Cheers
-Rob
Re: *Resolved* Checkbox VBA Syntax?
Hello,
how can I do it Office 2019 ?
I cant copy ant paste Your CheckBox :(
Where is toolbox toolbar in Office 2019 ?
Quote:
Originally Posted by
RobDog888
No prob.
Yes, I added the checkbox from the toolbox toolbar and not
the checkbox from the forms collection.
Re: *Resolved* Checkbox VBA Syntax?
this is an old thread from 2004 and the people who were posting here may well no longer visit this forum, you should have started a new thread
i do not have office 2019, but i guess you should look in the developer tab >controls
1 Attachment(s)
Re: *Resolved* Checkbox VBA Syntax?
I found, all is OK.
Thanks for the time :)
Attachment 182539
Quote:
Originally Posted by
westconn1
this is an old thread from 2004 and the people who were posting here may well no longer visit this forum, you should have started a new thread
i do not have office 2019, but i guess you should look in the developer tab >controls