Win a copy of Kotlin in Action this week in the Kotlin forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

Using Operators in Drop down  RSS feed

deepa durai
Posts: 18
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
There is a requirement in my project to add and delete a row onclick of a button.
Each row has a drop down which displays ("<",">","<=",">=") operators.

When i am using the below HTML code for displaying dropdowns ,add and delete functionalities working fine..
<select name="select13" class="TextBlackNormal">

But in case of JSF dropdown tag,add and delete fucntionalites are not working onclick of a button.But it displays the dropdown List.

<h:selectOneMenu value="#{ruleBlock.priceRangeFromOperator}">
<f:selectItems value="#{PriceVarianceRuleBean.priceRangeOpeList}"/>

I configured the priceRangeOpeList as
priceRangeOpeList.add(new SelectItem("<","<","<"));
priceRangeOpeList.add(new SelectItem(">",">",">"));

Add and delete functionlaites are working fine if i use below configuration for the drop down.but the the values in the drop down are dispalyed as (>,< like this instead of < , >).So i think the problem is with the operators.Can you please tell me how to display these opearators in the dropdown.
priceRangeOpeList=new ArrayList();
priceRangeOpeList.add(new SelectItem(">",">",">"));
priceRangeOpeList.add(new SelectItem("<","<",">"));

It is sorta covered in the JavaRanch Style Guide.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!