View Full Version : Variables with DOM?

04-13-2005, 06:56 PM
I have a database that I populate data into a table with. The individual records can be updated by clicking on an "active" checkbox. Onclick of the checkbox, a javascript function runs.

Here is my code:

function Activate(CurrentBox) {
alert("Activating Record");

Here is my problem:

There are several checkboxes in the table... and I use a variable to track the current checkbox, hence, the 'CurrentBox' reference in the function call. The help I need is inserting the 'CurrentBox' variable into my DOM reference. I'm sure the solution is an easy one, but I can't figure it out. Here is what I would love to do - but it obviously doesn't work...

... frmIdeaAdmin.cbActive<%=CurrentBox%>.checked ...

Any suggestions?

04-14-2005, 04:31 PM
Solved the issue.