This project has moved and is read-only. For the latest updates, please go here.

spservices autocomplete within a webpart (custom usercontrol) in

Sep 12, 2013 at 9:31 AM
I am trying days making things work here... But withi no success!
I have a webpart in my sharepoint 2007 - It"s an custom usercontrol that contains an asp textbox wich i want to create an autcomplete.

I thougth using the Spservices.Autocomplete so that i can work in front of the sharepint list.
But i can"t make it work !!

I am using Jquery 1.8.3.min.js
and using jquery.SPServices-0.7.2.min.js

here is my code :

$(document).ready(function() {
    WebURL: "",
    sourceList: "{7EF4DBBB-9F88-4AF8-B07A-A68A351C95E3}",
    sourceColumn: "Title",
    columnName: "Title",
    CAMLQuery: "<Contains><FieldRef Name='Title' /><Value Type='Text'></Value></Contains>",
    CAMLQueryOptions: "<QueryOptions></QueryOptions>",
    filterType: "Contains",
    numChars: 0,
    ignoreCase: true,
    highlightClass: "ms-bold",
    uniqueVals: false,
    slideDownSpeed: "fast",
    processingIndicator: "<img src='_layouts/images/REFRESH.GIF'/>", // NOTE: This option has been deprecated as of v0.6.0
    debug: false


I have 2 questions :

1.Can i use the spservices in a custom .net usercontrol ?
2.If i have an textbox dosent have to contain any event - who is fireng the event ?

Sep 12, 2013 at 8:20 PM

It's hard for me to give you a definitive answer because I can't access the page as its rendered in your environment. However, the SPAutocomplete function (like all of the value-added functions in SPServices) look for specific elements in the page based on what SharePoint is expected to render. Your markup is undoubtedly different.

You might also consider using jQueryUI's autocomplete function, feeding the data to it using GetListItems calls.