icefaces


How to get values in dropdown list from database in icefaces?


i just wanna list the list of employee names from database in the dropdown list using ice faces . can anyone suggest me how to write the query in icefaces page to get the list of employees in the database . say table name is "employee" .
Thanks in advance .
I do it like this.
in your bean call your business class
e.g:
ArrayList<SelectItem> selectEmployees = new ArrayList<SelectItem>();
ArrayList<Employee> employees = company.getEmployees(); //this one calls the EmployeeDAO to get the records from database.
for(int i = 0; i < employees.size(); i++){
selectEmployees.add(new SelectItem(employes.get(i).getId(),employees.get(i).getName));
}
now you can use selectEmployees as the value of the selectOneMenu.

Related Links

<ace:list> : Prevent an element to be draggable?
Alternative for SingleCopyStateManagerImpl in icefaces 3.3
Iceface 1.8 not working properly in IE11
Dynamic styling with IceFaces: how can I change the color of the outputText at the time of rendering?
icefaces outputConnectionStatus in javascript
How can I add a title to a disabled icefaces commandbutton?
Hide menuBar on click icefaces
ice:paneConfirmation - is it really so bad?
SessionRenderer not rendering throws ViewExpiredException
icefaces 1.8.2 Datapaginator unexpected PaneltabSet content swap
How can i download ICEfaces-1.7.0 Netbeans plugin?
Icefaces ace:autoCompleteEntry not working
ICEFaces: values for the “icon” attribute
EffectQueue and chaining effects in IceFaces 1.8
Ace Datatable row selector with paginator
How to customize internal server error popup?

Categories

HOME
tensorflow
jenkins-plugins
udp
meshlab
checkbox
freepascal
drupal-7
antivirus
matplotlib
h2
jrebel
dataframe
jboss7.x
onsen-ui2
simple-injector
medium-editor
jquery-terminal
alfresco-share
pyyaml
ng-show
tree-traversal
propel2
jni
explode
data-cleansing
branch
osmdroid
hash-collision
interrupt-handling
chrome-native-messaging
piecewise
apache-cloudstack
helix-3d-toolkit
exponential
spreedly
von-neumann
geomesa
sidr
forecasting
polyfills
ddms
onbackpressed
nashorn
microdata
datalog
constants
intersystems-ensemble
median
mod-fcgid
startapp
vcf
dimple.js
bnd
svn-merge
settimeout
windows-azure-pack
mongoose-populate
software-product-lines
image-editing
codesign
fill
direct3d12
registrykey
futuretask
abas
wif
ffserver
java-melody
symfony-2.6
sysctl
cocoascript
sortable
libssh2
facebook-wall
system.web
picat
voldemort
android-json-rpc
angulartics
real-time-updates
document-database
asp.net-mvc-scaffolding
astyanax
html-form-post
mstsc
android-contextmenu
icsharpcode
web-safe-fonts
getstring
hobo
exitstatus
carbide
revert
external-assemblies
soft-keyboard
standardized
rd

Resources

Mobile Apps Dev
Database Users
javascript
java
csharp
php
android
MS Developer
developer works
python
ios
c
html
jquery
RDBMS discuss
Cloud Virtualization
Database Dev&Adm
javascript
java
csharp
php
python
android
jquery
ruby
ios
html
Mobile App
Mobile App
Mobile App