identifying which radio button i clicked

M

monika

I move from one form to another when I click to a radio button. I can
identify which radio button I clicked by trapping its value. but my problem
is that there are a set of radio buttons followed by values being displayed
from a join table.

I want to know the values displayed from the table. so that based on which I
can do my further processing. Like the radio button is showing the name of
student, his id, story id...and 2-3 more things. when I select the first
radio button (its value = 0 ),
how can I know that the selected one is for which student_id and for which
story_id.???

here is my code:
<%
DIM SQL
DIM RSA
DIM BGC
dim iCount

iCount = 0
set RSA = Server.CreateObject("ADODB.Recordset")
RSA.OPEN "SELECT sc.student_id,si.student_name,sc.story_id,
sc.status_student, tc.status_teacher FROM student_content sc, student_info
si, teacher_content tc, story_table st where (sc.student_id = si.student_id
and sc.story_id = st.story_id) and (tc.student_id = si.student_id)",
"DSN=school"

Do while not RSA.EOF
%>
<html>
<head>
<title> none </title>
</head>
<body>
<form method="post" action="doc1.asp">
<table>
<tr>
<td><input type=radio name=RR value=<%=iCount%>></input> <%= RSA.Fields
("student_id").Value %></td>
<td bgcolor=" & BGC & "> <%= RSA.Fields ("student_name").Value %></td>
<td bgcolor=" & BGC & "> <%= RSA.Fields ("story_id").Value %></td>
<td bgcolor=" & BGC & "> <%= RSA.Fields ("status_student").Value%></td>
<td bgcolor=" & BGC & "> <%= RSA.Fields ("status_teacher").Value %></td>
</tr>
</table>
</body>
</html>
<%
iCount = iCount + 1
rsa.movenext
loop
%>
<p align="center">
<input type="submit" value="Submit" >
</p>

thanks
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,755
Messages
2,569,535
Members
45,007
Latest member
obedient dusk

Latest Threads

Top