View Full Version : combo box
01-26-2005, 04:09 AM
Currently the system is using J2EE. How can I populate the member's policy in the combo box after input member ID?
For example, this member ID:12345 have 2 policy which are P1 and P2.
Member ID : 12345
Policy : "Combo box here will auto populate 'P1' and 'P2' after 12345 input.
Thanks & Regards
01-26-2005, 01:31 PM
Well I'm thinking that you already have the alogirthm to calculate/display the user policy based on the user number so here is my simple suggestion:
<input type=text onChange='showPolicy()' name='memberID' value='Enter your member iD'>You could include an onChange event in there that when the user enters data in the fields and comes out of the field that policy is shown
<input type=text onkeyUp='showPolicy()' name='memberID' value='Enter your member iD'>
You could use the onkeyup event to get a real time showing of the member id. As in, each time the user types a letter the code would be run. I suggest you use the first instance depending on the length of the algorithm... as u might not want to run the code each time the user types a letter if the code is REALLY long... that might just slow up the typin process into the combo box.
If u wanna use the latter and the code to calculate the policy is LONG then you should include in your code lil things that will exit the code, like say first you could check to see if the string length is okay.... if not exit.....
Hope something above helps ya!
Powered by vBulletin® Version 4.2.2 Copyright © 2017 vBulletin Solutions, Inc. All rights reserved.