Visual Basic .NET » ASP.NET General Discussion
Autosuggest Text box????? -- bubberz --


Has anyone tried this yet with the AJAXPro.dll?

Thanks!

-- bubberz --


Thanks Albert!

I actually just found this link right after my post...and I've been trying to work on it this morning.

I get "object expected" on the first line of the autocomplete.js:
addNamespace("MS.Web.AutoComplete");

I tried adding my project name, WPG, and it still didn't work. Same error. WPG("MS.Web.AutoComplete");
Any ideas?

Thanks!

-- bubberz --


I'm also getting a "Object Required" for the last line:
function init() {
var x = new MS.Web.AutoCompleteDataTable("searchCustomerID", 10);

x.getDisplay = function(item) {
return (item != null ? item.Authority : "");
}
x.getValue = function(item) {
return (item != null ? item.Authority.toString().trimRight() : "");
}
x.getData = function() {
Namespace.ClassName.AjaxMethod(this.ele.value, this.count,
this.callback.bind(this));
}
}
addEvent(window, "load", init);

My code behind, in VB, is trying to pull a single field right now in order to populate the first text box, which is a person's last name then first name, "Auth".
*******
*******

<AjaxPro.AjaxMethod()> _
Public Function SearchAdvanced(ByVal orderNumber As String, ByVal customerID As Integer, ByVal count As Integer) As DataTable
Dim ds As DataSet = New DataSet
Dim cmd As New SqlCommand("SELECT Auth FROM AuthTBL WHERE Auth like @CustomerID")
cmd.Parameters.Add("@CustomerID", customerID)
Try
sCon1.Open()
Dim da As SqlDataAdapter = New SqlDataAdapter(cmd)
da.Fill(ds)
sCon1.Close()
Catch
Return Nothing
End Try
'Return ds.Tables
Return ds.Tables(0)

End Function

-- AlbertWeinert --


bubberz schrieb:
Has anyone tried this yet with the AJAXPro.dll?

http://munich.schwarz-interactive.de/autocomplete.aspx 


--
Freundliche Grüße

Albert Weinert

http://der-albert.com 

[Submit Comment]Home