teblack
Programmer
- Apr 30, 2004
- 45
I have a asp page that display a table of people with a radio button to select that individual for editing. Currently once you select a radio button you then click "SELECT" button. But the users want the page to fire imediatly once a radio button is selected, thus removing the second step of pressing the "SELECT" button. The attached code is what I'm using to attempting to use. Once the radio button is selected, that indx value is supposed to be sent to the next page for use in retireval of the correct data, it. The problem is that we can not get the index value (I) passed over to the next screen.
for i = 0 to UBound(vaCompanyUsers,2)
userpkkey = vaCompanyUsers(FldPos("pk_contactid",saCompanyUsersFieldNames),i)
userfname = vaCompanyUsers(FldPos("firstname",saCompanyUsersFieldNames),i)
userlname = vaCompanyUsers(FldPos("lastname",saCompanyUsersFieldNames),i)
Any suggestion"?
Thanks in advance for the help
TBlack -
for i = 0 to UBound(vaCompanyUsers,2)
userpkkey = vaCompanyUsers(FldPos("pk_contactid",saCompanyUsersFieldNames),i)
userfname = vaCompanyUsers(FldPos("firstname",saCompanyUsersFieldNames),i)
userlname = vaCompanyUsers(FldPos("lastname",saCompanyUsersFieldNames),i)
Code:
userphone = FormatPhone(vaCompanyUsers(FldPos("phone",saCompanyUsersFieldNames),i))
userphoneext = vaCompanyUsers(FldPos("phoneext",saCompanyUsersFieldNames),i)
userfax = FormatPhone(vaCompanyUsers(FldPos("fax",saCompanyUsersFieldNames),i))
userfaxext = vaCompanyUsers(FldPos("faxext",saCompanyUsersFieldNames),i)
userid = vaCompanyUsers(FldPos("username",saCompanyUsersFieldNames),i)
useremail = vaCompanyUsers(FldPos("email",saCompanyUsersFieldNames),i)
phones = ""
if userfax > "" then
phones = phones & userphone & " ext. " & userphoneext & "<br>"
phones = phones & userfax
else
phones = phones & userphone & " ext. " & userphoneext
end if
roles = ""
if vaCompanyUsers(FldPos("isAdministrator",saCompanyUsersFieldNames),i) > 0 then
roles = roles & "Administrator <br>"
end if
if vaCompanyUsers(FldPos("isPaymentEntry",saCompanyUsersFieldNames),i) > 0 then
roles = roles & "Payment Scheduler <br>"
end if
if vaCompanyUsers(FldPos("isPaymentApprover",saCompanyUsersFieldNames),i) > 0 then
roles = roles & "Payment Approver <br>"
end if
if vaCompanyUsers(FldPos("isNewHireEntry",saCompanyUsersFieldNames),i) > 0 then
roles = roles & "New Hire Reporter"
end if
if vaCompanyUsers(FldPos("isBasicUser",saCompanyUsersFieldNames),i) > 0 then
roles = roles & "Basic User"
end if
%>
<tr>
<%if Session("loginid") = userpkkey or Session("isAdministrator") = true then %>
<td valign="top" align="center" width="60">
<input type="radio" name="selected<%=i%>" value="<%=i%>"
onmousedown="javascript: document.UserSelect_Form.selected.value =
document.UserSelect_Form.selected<%=i%>.value;
document.UserSelect_Form.submit();">
</td>
<%else%>
<td valign="top" align="center" width="60" bgcolor=DarkGray><input type="radio" name="selected1" id="selected1" disabled value="<%=i%>"></td>
<%end if%>
<td valign="top" align="center" width="175"><%=rtrim(userfname)%> <%=rtrim(userlname)%></td>
<td valign="top" align="center" width="60"><%=userid%></td>
<td valign="top" align="left" width="200"><%=phones%></td>
<td valign="top" align="center" width="175"><%=useremail%></td>
<td valign="top" align="center" width="175"><%=roles%></td>
</tr>
<%Next %>
</table>
<input type="hidden" name="selected">
Any suggestion"?
Thanks in advance for the help
TBlack -