473,387 Members | 1,510 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,387 software developers and data experts.

AutoComplete extender

I’m trying to figure out how I can achieve the followings:
While typing in a textbox, making a webservice call gets possible values
from DB in Autocomplete textbox. I need to validate that the user selection
is one of the value list in AutoComplete textbox. If not, I need to display
a warning message. Does anyone know how I can do this? I can do this by
customValidate controls. But how. Could you please give me code as
wellThanks in advance,
Sep 13 '07 #1
1 2141
On Sep 14, 10:48 am, bobby <bo...@discussions.microsoft.comwrote:
I'm trying to figure out how I can achieve the followings:

While typing in a textbox, making a webservice call gets possible values
from DB in Autocomplete textbox. I need to validate that the user selection
is one of the value list in AutoComplete textbox. If not, I need to display
a warning message. Does anyone know how I can do this? I can do this by
customValidate controls. But how. Could you please give me code as
wellThanks in advance,
in the aspx

<asp:Label ID="lblRegion" runat="server"
AssociatedControlID="txtRegion" Text="region:" style="color: White" />
<conduit:TextBox ID="txtRegion" runat="server"
AutoPostBack="true" Width="200" />
<AjaxControlToolkit:AutoCompleteExtender ID="AutoRegion"
runat="server"
TargetControlID="txtRegion"
ServicePath="~/services/AutoComplete.asmx"
ServiceMethod="RegionSelectByCountryCode"
CompletionSetCount="12"
MinimumPrefixLength="1"
ContextKey="0" />
<asp:CustomValidator ID="valRegion" runat="server"
Text="please enter a valid region" />
<br />
in the .vb
(pseudocode because I use custom data component)

make storedprocedure("RegionSelectByRegion")
add parameter txtRegion.Text
try
dim oreader as reader = storedprocedure.executereader
valRegion.IsValid = oreader.read

Catch ex As Exception
End Try

hope this helps

Sep 13 '07 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

11
by: Brad | last post by:
To DB2 Personal Developer Edition GIS users: How do I acquire a spatial extender license key for the DB2 PDE? I expected to be able to use it right out of the box. Brad
0
by: GMartin | last post by:
Does anyone know of a way to trigger code after an AutoComplete Extender choice is selected by a user? I would like to populate a Form and/or other fields if the user selects one of the offered...
0
by: adelscott | last post by:
Hi, I'm using an autocomplete extender and I would like to retrieve the ID that goes with the label. IE: Label, ID "Mr John","CLIENT0001" "Mr Doe","CLIENT0002" etc..
1
by: wkerplunk | last post by:
Below is what I have build with several different languages. It works great but I need help, I am stuck. When you click on an item in the dropdown autocomplete div it does a mousedown function...
1
by: Juan Romero | last post by:
Hi guys, I have an ajax autocomplete extender working fine but I would like to populate the textbox with a different value from what the user selects. For example: User selects "CODE -...
1
by: phpmel | last post by:
Hi Guys, I cant understand why my textbox is doing nothing. I want a TextBox that would search a database and give suggestions based on what the user types on every keystroke. After doing some...
1
by: =?Utf-8?B?UmV5?= | last post by:
I have a textbox and linked that with the autocomplete extender I have created the webservice and the WebMethod and returns a ToArray to the textbox. Everything works when I type normal string...
0
by: JM_newsgroups | last post by:
Hello, I see how DynamicPopulate allows one to use the AJAX loading icon with CSS. Does anybody know how to do this with the AutoComplete extender? I want to provide a little user feedback. I...
0
by: Radu | last post by:
Hi. I have an autocomplete extender <style type="text/css"> .list2 { border: 1px solid DarkGray; list-style-type: none; margin: 0px; background-color: #FFF;
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.