Hello all. I have an app that allows a user to apply multiple Courses and Required Reading to a new Qual. So, the user will type in the name of the new qual, and from a series of checkboxes (quantity varies), they will assign various reading and courses to this new qual. I need to be able to run though each checkbox and see if it has been checked, and if so, I need to enter the values in the database. The problem that I am having is that each checkbox will have 2 values, e.g. CourseNO and CourseDesc. These are two separate fields in the database for other reasons. So, how would I cycle through them and get these two values?
I am creating the checkboxes with the following code:
<% While Not rsGetCourse.EOF %>
<td align="right"> </td>
<td><label> <input type="checkbox" name="cbxReqCourse" id="cbxReqCourse" /> </label><%=rsGetCourse("dbCourseNo")%> - <%=rsGetCourse("dbCourse")%></td>
x = x+1
Would I just put the value of the checkbox to both variables separated by some special character and then just use some sort of Trim function to separate the variables and add them to the database?