yoeddy25
Sep 18th, 2000, 09:13 AM
I have a combo box which selects the first entry with its status set to false. When I select this value I want to automatically update its status to true, so it isn't selected again. I've tried the following before closing the recordset.
rstemp.edit
rstemp("status")=true
rstemp.update
Any ideas anyone?? Here's my original code
<%DSN= "dsn=regno;uid=;pwd="
SQL="SELECT regno FROM testreg1 WHERE type ='Free to air (test)' AND status = false"
set conntemp=server.createobject("adodb.connection")
conntemp.open DSN
set rstemp=conntemp.execute(SQL)
if rstemp.eof then
response.write "no data for<br>"
response.write SQL
conntemp.close
set conntemp=nothing
response.end
end if%>
<select name="RegNo" size="1">
<% rstemp.movefirst %>
<option> <%=RStemp(0)%> </option>
</select>
<% rstemp.close
set rstemp=nothing
conntemp.close
set conntemp=nothing %>
rstemp.edit
rstemp("status")=true
rstemp.update
Any ideas anyone?? Here's my original code
<%DSN= "dsn=regno;uid=;pwd="
SQL="SELECT regno FROM testreg1 WHERE type ='Free to air (test)' AND status = false"
set conntemp=server.createobject("adodb.connection")
conntemp.open DSN
set rstemp=conntemp.execute(SQL)
if rstemp.eof then
response.write "no data for<br>"
response.write SQL
conntemp.close
set conntemp=nothing
response.end
end if%>
<select name="RegNo" size="1">
<% rstemp.movefirst %>
<option> <%=RStemp(0)%> </option>
</select>
<% rstemp.close
set rstemp=nothing
conntemp.close
set conntemp=nothing %>