BlackBerryForums.com : Your Number One BlackBerry Community      

»Sponsored Links




Closed Thread
 
LinkBack Thread Tools
  (#1 (permalink)) Old
rstew Offline
New Member
 
Posts: 2
Join Date: Oct 2006
Model: 7250
Angry onkey events, wap-input nightwares. - 10-06-2006, 02:34 PM

I've got straight xHTML running on asp pages.
My clients have to enter SKU number in a input textbox
The number are all over the place (e.g. 0048N-0A or 07052-005, etc.)

The dilemma:

1. Blackberrys have shared alpha/number keys
(maybe some day someone will add a row number keys along the top or bottom)
2. Browser has no support for JavaScript or DOM onkey events so I cannot capture key events.
3. Little support for css styles to hide, etc.

Is there any way to toggle a single textbox in and out of alpha and number format using just JavaScript?

I've tried:

1. javascript:setinterval(function,50) to check input characters and change them. however the Zero key is also a shift button so I cannot trap the keycode event.
2. I tried using:
input id="2" style='width:40; -wap-input-format:"*X"' type="text" size="1"
plus a timer to trap the space key to switch classname or style to -wap-input-format:"*A"'

(guess what? classname not supported. How no idea how or if you can change the -wap-input-format using document.form.id.style.
3. I tried to use two textbox (hide and show one - append values during the switch) visibility, hide, hidden, whatever does not work.

As to why JavaScript key events where omitted from a key input device is beyond me. Help please!


Oh by the way I tried to make my code smaller from this:

if (document.getElementById(1).value == '') {document.getElementById('checkbtn').focus();}

with this:

eid=document.getElementById;

if (eid(1).value == '') {eid('checkbtn').focus();}

guess what?

Finally, when is the next browser to be released?
   
Sponsored Links
Please Login or Register to Remove these Advertisements!

Closed Thread


Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On






Copyright © 2004-2008 BlackBerryNews.com, BlackBerryFAQ.com, BlackBerryForums.com.
The names RIM © and BlackBerry © are registered Trademarks of Research In Motion Limited.
Powered by vBulletin® Version 3.6.8
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
SEO by vBSEO 3.0.1