AutoCompleteExtender

  • Thread starter Thread starter shapper
  • Start date Start date
S

shapper

Hello,

I am using an AutoCompleteExtender.
I created the .asmx file with the method GetWordList:

<WebMethod()> _
Public Function GetWordList(ByVal prefixText As String, ByVal count
As Integer) As String()
Dim words As New Generic.List(Of String)

' GET words from database using TypeId as parameter ...
...
categories.Sort()
Return categories.ToArray
End Function

I don't have any problems with connecting to the database.

I just don't know how to pass the parameter TypeId to GetWordList.

As fas as I know the inputs of the AutoCompleteExtender method must
be:
ByVal prefixText As String, ByVal count As Integer

I can only change the name of the method.

Thanks,
Miguel
 
shapper said:
Hello,

I am using an AutoCompleteExtender.
I created the .asmx file with the method GetWordList:

<WebMethod()> _
Public Function GetWordList(ByVal prefixText As String, ByVal count
As Integer) As String()
Dim words As New Generic.List(Of String)

' GET words from database using TypeId as parameter ...
...
categories.Sort()
Return categories.ToArray
End Function

I don't have any problems with connecting to the database.

I just don't know how to pass the parameter TypeId to GetWordList.

As fas as I know the inputs of the AutoCompleteExtender method must
be:
ByVal prefixText As String, ByVal count As Integer

I can only change the name of the method.

Thanks,
Miguel

The autocompleteextender will take the value found in the textbox
(TargetControlID) associated with the extender and use that as the
parameter. That should be your TypeId.

Hope this helps
LS
 
Back
Top