wood burning stoves 2.0*
The moose likes JSF and the fly likes Auto complete in JSF Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of Android Security Essentials Live Lessons this week in the Android forum!
JavaRanch » Java Forums » Java » JSF
Bookmark "Auto complete in JSF" Watch "Auto complete in JSF" New topic

Auto complete in JSF

hareendra seneviratne

Joined: Oct 07, 2010
Posts: 1
Hi all,

1.)I'm using Visual Web Java Server Faces packed with Net beans IDE 5.5.
2) AutoComplete_Create('txtUserId', data); is a java script method which binds auto suggestions to an element identified by 'txtUserId'. Second param, 'data' is the suggestions array.
3) can I use this method to bind suggestions to an <webuijsf:textField > object?
4) I tried following. But not succesfull
<webuijsf:textField binding="#{MaintainUserOfficer.txtUserId}" id="txtUserId" style="left: 288px; top: 48px; position: absolute" />
<script language="javascript" type="text/javascript">
data = ('aaaaa','ssss','qqqqqqq')
AutoComplete_Create('txtUserId', data);
/////AutoComplete_Create('color', ['red', 'orange', 'green', 'black', 'pink', 'grey', 'mauve', 'turquoise', 'blue', 'purple'].sort(), 6);

5) Any idea how to add the auto suggetion feature to <webuijsf:textField > ???
It is sorta covered in the JavaRanch Style Guide.
subject: Auto complete in JSF
Similar Threads
executing a javascript function from a servlet
how to implement autocomplete in javascript?
passing java-script value to java-bean-property
Passing huge string to JSP..
request.getParamter returning null