Computing.Net > Forums > Programming > javascript checkbox event handling

Computer Problems? Computing.Net has over 1,000,000 posts about all things technology related! Over 90% answered within 24 hours! Click here to start participating now! Also, be sure to check out the New User Guide.

javascript checkbox event handling

Reply to Message Icon

Name: nascent (by mboto)
Date: June 8, 2003 at 08:11:44 Pacific
OS: win98
CPU/Ram: 600/256
Comment:

I am trying to make an easy game in javascript. You have to click 25 checkboxes in the fastest time. When you click on a checkbox it calls a function called start. Everytime i have tried to call this function i have hit a brick wall. I thought this would be pretty straight forward.

The checkboxes are aranged in a front page table. If i use :---" ", i get the error "Object doesn't support this action" if i use :- " ", i get absolutely nothing not even an error. I have alert testing message inside the statt function on the first line so this should be calling if it is being executed, but the script is acting as though there is programmng there. Anyone know how i can avoid this?

Cheers
Adam



Sponsored Link
Ads by Google

Response Number 1
Name: nascent (by mboto)
Date: June 8, 2003 at 08:14:31 Pacific
Reply:

Sorry the first use should read {input type="checkbox" name="2" value="ON" onClick"start()"} where { = rigght angle bracket etc.. this post removes them

and the second reads
{input type="checkbox" name="2" value="ON" onClick("start()")}


0

Response Number 2
Name: SN
Date: June 8, 2003 at 11:05:38 Pacific
Reply:

I think it should be onClick="start()"; (you forgot the =)

-SN


0

Response Number 3
Name: nascent (by mboto)
Date: June 9, 2003 at 00:54:28 Pacific
Reply:

i have tried putting an equals sign in there and a few other combinations. just can't get it to call a function. any toher suggestions


0

Response Number 4
Name: SN
Date: June 9, 2003 at 09:25:51 Pacific
Reply:

Nothing is coming to me off the top of my head...Can you post a link?
-SN


0

Sponsored Link
Ads by Google
Reply to Message Icon

Related Posts

See More







Post Locked

This post is quite old and has been locked from receiving new replies. Please create a new posting instead.


Go to Programming Forum Home


Sponsored links

Ads by Google


Results for: javascript checkbox event handling

JavaScript Checkbox www.computing.net/answers/programming/javascript-checkbox/2245.html

Java Event handling www.computing.net/answers/programming/java-event-handling/5391.html

ListView Mouse Event Handling www.computing.net/answers/programming/listview-mouse-event-handling/8562.html