• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Paul Clapham
  • Ron McLeod
  • Bear Bibeault
  • Liutauras Vilda
Sheriffs:
  • Jeanne Boyarsky
  • Tim Cooke
  • Junilu Lacar
Saloon Keepers:
  • Tim Moores
  • Tim Holloway
  • Stephan van Hulst
  • Jj Roberts
  • Carey Brown
Bartenders:
  • salvin francis
  • Frits Walraven
  • Piet Souris

EL Syntax exception - javax faces el ReferenceSyntaxException

 
Greenhorn
Posts: 1
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi

I am facing EL Syntax exception in my jsf page.

I am using myfaces JSF Implementation. I have a data table , with data scorller. I have to be show only one row in table and provide pagination. When ever user press the next icon in the pagination, I want to capatue the row details that are displayed.

for this I have written a action listner ( t:updatActionLister)for next button. For update action listern I am using EL expression to get the displayed row object. and assing to property in my managed bean.

When I am running below code I am getting below exception.

javax.faces.el.ReferenceSyntaxException - Cannot convert index to int for base java.util.ArrayList and index #{pageIndex}


Can any body help me to solve this issue.

Thanks in Advnce
Madhu

---------------
The JSF code
--------------
<h:form >

<h:panelGroup id="body">
<h:panelGrid columns="1" styleClass="scrollerTable2" columnClasses="standardTable_ColumnCentered" >
<t:dataTable id="data"
styleClass="scrollerTable"
headerClass="standardTable_Header"
footerClass="standardTable_Header"
rowClasses="standardTable_Row1,standardTable_Row2"
columnClasses="standardTable_Column,standardTable_ColumnCentered,standardTable_Column"
var="citation"
value="#{detailBaselineInputSelectionForm.citationsList}"
preserveDataModel="false"
rows="#{detailBaselineInputSelectionForm.rowCount}"
border="1">

<t:column width="100%">
<h:outputText styleClass="standard_bold" value="#{baselinecreator_messages['xpath']}" /><f:verbatim><br/></f:verbatim>
<h:outputText value="#{citation.xpath}" /><f:verbatim><br/></f:verbatim><f:verbatim><br/></f:verbatim>
<h:outputText styleClass="standard_bold" value="#{baselinecreator_messages['dms_serialnumber']}" /><f:verbatim><br/></f:verbatim>
<h:outputText value="#{citation.citingId}" /><f:verbatim><br/></f:verbatim><f:verbatim><br/></f:verbatim>
<h:outputText styleClass="standard_bold" value="#{baselinecreator_messages['sequence_number']}" /><f:verbatim><br/></f:verbatim>
<h:outputText value="#{citation.sequenceNr}" />
</t:column>


<f:facet name="footer" >
<t:dataScroller id="scroll_1"
fastStep="10"
pageCountVar="pageCount"
pageIndexVar="pageIndex"
styleClass="scroller"
paginator="false"
paginatorMaxPages="9"
paginatorTableClass="paginator"
paginatorActiveColumnStyle="font-weight:bold;"
immediate="true"
rowsCountVar="rowsCount"
firstRowIndexVar="firstRowIndex"
lastRowIndexVar="lastRowIndex"
actionListener="#{detailBaselineInputSelectionForm.scrollerAction}">

<f:facet name="previous" >
<t:graphicImage url="images/arrow-previous.gif" border="1" alt="Previous" />
<t:updateActionListener value="#{detailBaselineInputSelectionForm.citationsList['#{pageIndex}']}" property="#{detailBaselineInputSelectionForm.currentCitation}"></t:updateActionListener>
</f:facet>
<f:verbatim>     </f:verbatim>
<f:facet name="next">
<t:graphicImage url="images/arrow-next.gif" border="1" alt="Next" />
</f:facet>
<h:outputFormat value="#{baselinecreator_messages['document_citations']}" styleClass="standard" >
<f:param value="#{rowsCount}" />
<f:param value="#{displayedRowsCountVar}" />
<f:param value="#{firstRowIndex}" />
<f:param value="#{lastRowIndex}" />
<f:param value="#{pageIndex}" />
<f:param value="#{pageCount}" />
</h:outputFormat>
</t:dataScroller>

</f:facet>
</t:dataTable>

</h:panelGrid>
 
Sheriff
Posts: 14691
16
Eclipse IDE VI Editor Ubuntu
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I'm not into JSF (yet ;) ) but shouldn't it look like this :
 
There is no "i" in denial. Tiny ad:
Building a Better World in your Backyard by Paul Wheaton and Shawn Klassen-Koop
https://coderanch.com/wiki/718759/books/Building-World-Backyard-Paul-Wheaton
reply
    Bookmark Topic Watch Topic
  • New Topic