Just a matter of syntax
Hi, I am in trouble again !
from this
<form method="get" action= "<%= strURL %>">
<select name="headSearch">
<option>head1</option>
<option>head2</option>
<option>body1</option>
<option>body2</option>
</select>
<input type="submit" value="Submit Here" />
</form>
I am tring to use the result to do a select Distinct
objDC.Open "Driver={Microsoft Access Driver (*.mdb)}; DBQ=" & myPath & ";"
Set objRS = Server.CreateObject("ADODB.Recordset")
strSQL = "SELECT DISTINCT "'headSearch'" FROM aefe ORDER BY "'headSearch'",
objRS.Open strSQL, objDC, 0, 1
%>
I am having problems getting the syntax correct in
the line above
objRS.Open strSQL, objDC, 0, 1
%>
When I get it correct i then need
<div>
<form method="get" action= "<%= strURL %>">
<select name="search">
<option>--- Select Head Type ---</option>
<% Do While Not objRS.EOF %>
<option value= "<%=objRS.Fields("head1")%>"><%=objRS.Fields("head 1")%></option>
<% objRS.MoveNext
Loop %>
</select>
I simply need to replace the "head1 with the Variable
<%=objRS.Fields("head1")%>">
with
<%=objRS.Fields("headSearch")%>">
but I am ubnsure of the syntax here also
Pls Help
topshed
|