I am having trouble creating automatic form field. I am using a SQL query to populate a dropdown menu. I need it to filter text as the user enters data in the form field.
here is a copy of my code
Select One
<%
While (NOT rsJobNo.EOF)
%>
">
<%=(rsJobNo.Fields.Item("job_no").Value)%>
<%
rsJobNo.MoveNext()
Wend
If (rsJobNo.CursorType > 0) Then
rsJobNo.MoveFirst
Else
rsJobNo.Requery
End If
%>
thanks
Comments
Faustine
-------
: I am having trouble creating automatic form field. I am using a SQL query to populate a dropdown menu. I need it to filter text as the user enters data in the form field.
:
: here is a copy of my code
:
:
: Select One
: <%
: While (NOT rsJobNo.EOF)
: %>
: ">
: <%=(rsJobNo.Fields.Item("job_no").Value)%>
: <%
: rsJobNo.MoveNext()
: Wend
: If (rsJobNo.CursorType > 0) Then
: rsJobNo.MoveFirst
: Else
: rsJobNo.Requery
: End If
: %>
:
:
: thanks
:
Ex. If the dropdown were populated with names of all the months.
and the users types J it should filter out all months that don't start with J,(or maybe not filter just scroll through the recordset quicker) if the user types JUL, it should filter out JUNE (or just give them JULY).
I am not sure how to approch this problem.
Thanks
What exactly is the trouble ?Are you getting any errors ? or is it that the select field has no value ?
:
: Faustine
: -------
:
: : I am having trouble creating automatic form field. I am using a SQL query to populate a dropdown menu. I need it to filter text as the user enters data in the form field.
: :
: : here is a copy of my code
: :
: :
: : Select One
: : <%
: : While (NOT rsJobNo.EOF)
: : %>
: : ">
: : <%=(rsJobNo.Fields.Item("job_no").Value)%>
: : <%
: : rsJobNo.MoveNext()
: : Wend
: : If (rsJobNo.CursorType > 0) Then
: : rsJobNo.MoveFirst
: : Else
: : rsJobNo.Requery
: : End If
: : %>
: :
: :
: : thanks
: :
:
:
:
: Ex. If the dropdown were populated with names of all the months.
: and the users types J it should filter out all months that don't start with J,(or maybe not filter just scroll through the recordset quicker) if the user types JUL, it should filter out JUNE (or just give them JULY).
:
: I am not sure how to approch this problem.
:
: Thanks
:
:
:
: What exactly is the trouble ?Are you getting any errors ? or is it that the select field has no value ?
: :
: : Faustine
: : -------
: :
: : : I am having trouble creating automatic form field. I am using a SQL query to populate a dropdown menu. I need it to filter text as the user enters data in the form field.
: : :
: : : here is a copy of my code
: : :
: : :
: : : Select One
: : : <%
: : : While (NOT rsJobNo.EOF)
: : : %>
: : : ">
: : : <%=(rsJobNo.Fields.Item("job_no").Value)%>
: : : <%
: : : rsJobNo.MoveNext()
: : : Wend
: : : If (rsJobNo.CursorType > 0) Then
: : : rsJobNo.MoveFirst
: : : Else
: : : rsJobNo.Requery
: : : End If
: : : %>
: : :
: : :
: : : thanks
: : :
: :
: :
:
USE JAVASCRIPT
Please enter the first few letters of the item you are looking for.
Select One
<%
While (NOT rsJobNo.EOF)
%>
">
<%=(rsJobNo.Fields.Item("job_no").Value)%>
<%
rsJobNo.MoveNext()
Wend
If (rsJobNo.CursorType > 0) Then
rsJobNo.MoveFirst
Else
rsJobNo.Requery
End If
%>
Not tested!!!!
/Haxme
: :
: : Ex. If the dropdown were populated with names of all the months.
: : and the users types J it should filter out all months that don't start with J,(or maybe not filter just scroll through the recordset quicker) if the user types JUL, it should filter out JUNE (or just give them JULY).
: :
: : I am not sure how to approch this problem.
: :
: : Thanks
: :
: :
: :
: : What exactly is the trouble ?Are you getting any errors ? or is it that the select field has no value ?
: : :
: : : Faustine
: : : -------
: : :
: : : : I am having trouble creating automatic form field. I am using a SQL query to populate a dropdown menu. I need it to filter text as the user enters data in the form field.
: : : :
: : : : here is a copy of my code
: : : :
: : : :
: : : : Select One
: : : : <%
: : : : While (NOT rsJobNo.EOF)
: : : : %>
: : : : ">
: : : : <%=(rsJobNo.Fields.Item("job_no").Value)%>
: : : : <%
: : : : rsJobNo.MoveNext()
: : : : Wend
: : : : If (rsJobNo.CursorType > 0) Then
: : : : rsJobNo.MoveFirst
: : : : Else
: : : : rsJobNo.Requery
: : : : End If
: : : : %>
: : : :
: : : :
: : : : thanks
: : : :
: : :
: : :
: :
: USE JAVASCRIPT
:
:
:
:
:
:
:
:
:
:
:
:
:
:
:
:
: Please enter the first few letters of the item you are looking for.
:
:
:
:
:
: Select One
: <%
: While (NOT rsJobNo.EOF)
: %>
: ">
: <%=(rsJobNo.Fields.Item("job_no").Value)%>
: <%
: rsJobNo.MoveNext()
: Wend
: If (rsJobNo.CursorType > 0) Then
: rsJobNo.MoveFirst
: Else
: rsJobNo.Requery
: End If
: %>
:
:
:
:
:
:
:
:
:
: Not tested!!!!
: /Haxme
:
:
: ________________________
Thank you. I will try it.
I also wanted to do exactly this! And the code of Haxme is working wonders.
But there is one flaw...
When I start typing the name, the other names (starting with other characters) disapper from the listbox!
This is obviously something that I don't want.
I'm sure Haxme can fix this.
Regards,
Surajit
: USE JAVASCRIPT
:
:
:
:
:
:
:
:
:
:
:
:
:
:
:
:
: Please enter the first few letters of the item you are looking for.
:
:
:
:
:
: Select One
: <%
: While (NOT rsJobNo.EOF)
: %>
: ">
: <%=(rsJobNo.Fields.Item("job_no").Value)%>
: <%
: rsJobNo.MoveNext()
: Wend
: If (rsJobNo.CursorType > 0) Then
: rsJobNo.MoveFirst
: Else
: rsJobNo.Requery
: End If
: %>
:
:
:
:
:
:
:
:
:
: Not tested!!!!
: /Haxme
:
:
: