473,320 Members | 2,145 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,320 software developers and data experts.

Predicitive input

Is it possible to modify a HTML list box properties so that it doesn't
scroll to the letter pressed. I have created a bit of code to allow the
list box to scroll to the the first 5 characters entered. Ie if the
user selects the list box and types 'compu' the listbox will scroll to
'Computer'. My problem is with the default behaviour of the listbox.
After the 'computer' option is selected the listbox moves to a word
begining with 'u' my last entered character. Is there anyway arround
this? My code is executed on the keyup event on the listbox <select
size="5" multiple="true" id="b" onkeyup="DoSelect()">.
--
Posted via Mailgate.ORG Server - http://www.Mailgate.ORG
Jul 23 '05 #1
4 1144
In article <d9************************************@mygate.mai lgate.org>,
he********@hotmail.com enlightened us with...
Is it possible to modify a HTML list box properties so that it doesn't
scroll to the letter pressed. I have created a bit of code to allow the
list box to scroll to the the first 5 characters entered. Ie if the
user selects the list box and types 'compu' the listbox will scroll to
'Computer'. My problem is with the default behaviour of the listbox.
After the 'computer' option is selected the listbox moves to a word
begining with 'u' my last entered character. Is there anyway arround
this? My code is executed on the keyup event on the listbox <select
size="5" multiple="true" id="b" onkeyup="DoSelect()">.


I'm sure there is, but unless this is for an intranet application, it's
a Bad Idea to change the default behavior of a component. Usability
studies show that once we actually get people used to things, they
really don't like it when you change the behavior of that thing.
It's kind of like teaching someone to drive, then changing the gas pedal
to the left and the brake to the right. ;)

If you still want to do it, cancel the event according to the browser of
choice. Netscape and IE do it a bit differently.

--
--
~kaeli~
With her marriage, she got a new name and a dress.
http://www.ipwebdesign.net/wildAtHeart
http://www.ipwebdesign.net/kaelisSpace

Jul 23 '05 #2
"Clive Moore" <he********@hotmail.com> wrote in message
news:d9************************************@mygate .mailgate.org...
Is it possible to modify a HTML list box properties so that it doesn't
scroll to the letter pressed. I have created a bit of code to allow the
list box to scroll to the the first 5 characters entered. Ie if the
user selects the list box and types 'compu' the listbox will scroll to
'Computer'. My problem is with the default behaviour of the listbox.
After the 'computer' option is selected the listbox moves to a word
begining with 'u' my last entered character. Is there anyway arround
this? My code is executed on the keyup event on the listbox <select
size="5" multiple="true" id="b" onkeyup="DoSelect()">.
--
Posted via Mailgate.ORG Server - http://www.Mailgate.ORG


Here's something I found and adapted for my use:

// Cooking with JavaScript & DHTML
// Bonus Recipe: Typing select Element Choices in IE for Windows
// http://www.oreillynet.com/pub/a/java...nygoodman.html
// http://www.oreillynet.com/lpt/a/4135
Jul 23 '05 #3
In article
<d9************************************@mygate.mai lgate.org>, Clive
Moore <he********@hotmail.com> wrote:
Is it possible to modify a HTML list box properties so that it doesn't
scroll to the letter pressed. I have created a bit of code to allow the
list box to scroll to the the first 5 characters entered. Ie if the
user selects the list box and types 'compu' the listbox will scroll to
'Computer'. My problem is with the default behaviour of the listbox.
After the 'computer' option is selected the listbox moves to a word
begining with 'u' my last entered character. Is there anyway arround
this? My code is executed on the keyup event on the listbox <select
size="5" multiple="true" id="b" onkeyup="DoSelect()">.


Why not have a separate input box below the select list where you enter
the search term. Do the onkeyup="DoSelect() in the input box.

--
Dennis Marks
http://www.dcs-chico.com/~denmarks/
To reply change none to dcsi.
-----= Posted via Newsfeeds.Com, Uncensored Usenet News =-----
http://www.newsfeeds.com - The #1 Newsgroup Service in the World!
-----== Over 100,000 Newsgroups - 19 Different Servers! =-----
Jul 23 '05 #4


Thanks for your reply. This is what ive been looking for.
Clive

--
Posted via Mailgate.ORG Server - http://www.Mailgate.ORG
Jul 23 '05 #5

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

Similar topics

0
by: gotcha | last post by:
I have a little code to add multiple items to a shopping cart based page. This code works perfect, but it adds all of the info to the same input fields every time it loops. I need it to change...
3
by: david | last post by:
HI! Im trying to make "HTML form" into automatic. 1. If I get 18 numbers like: A B C D E F . . . . 2. How can I put those 18 numbers automatically into 6 numbers format like: A B C D E F
2
by: SophistiCat | last post by:
Hi, I am working on a computational program that has to read a number of parameters (~50) from an input file. The program contains a single class hierarchy with about a dozen member-classes or...
2
by: Cranky | last post by:
Ok, here is my scenario: I need to input numbers using my handheld IPAQ. I figured out how to create an online numeric keypad for inputting numbers into an input field, what I need to know is how...
3
by: acecraig100 | last post by:
I am fairly new to Javascript. I have a form that users fill out to enter an animal to exhibit at a fair. Because we have no way of knowing, how many animals a user may enter, I created a table...
3
by: cbradio | last post by:
Hi, I am having trouble developing a form in a restricted environment. My sample code is found below my message (sorry I don't have a URL). Basically, without a doctype, the form displays properly...
18
by: Diogenes | last post by:
Hi All; I, like others, have been frustrated with designing forms that look and flow the same in both IE and Firefox. They simply did not scale the same. I have discovered, to my chagrin,...
1
by: tcertain | last post by:
I am totally duh at javascript although I have 2 books trying to learn it. I am trying to add values to a form and have a calculate total at end. this is my form script. I have hours at end of...
1
by: printline | last post by:
Hello All I'm quite new to xml vs. PHP, so i hope someone can help with an issue i have been struggeling with. I have an html form, that when submitted, it should create an xml file, and save...
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
1
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: jfyes | last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
0
by: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
1
by: PapaRatzi | last post by:
Hello, I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...
0
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
1
by: Shællîpôpï 09 | last post by:
If u are using a keypad phone, how do u turn on JavaScript, to access features like WhatsApp, Facebook, Instagram....
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...

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.