Jun 6, 2018, 4:08 PM
11 Posts

How to sort repeat control view columns

  • Category: Custom JSF code (Eclipse IDE)
  • Platform: Windows
  • Release: All
  • Role: Developer
  • Tags:
  • Replies: 2

Hi All,

I am using a repeat control view for my xpage and not sure how to put sorting options for every column like regular view control column headers. Please guide me. I designed just two columns but there will be 8 columns.

<?xml version="1.0" encoding="UTF-8"?>
<xp:view xmlns:xp="http://www.ibm.com/xsp/core">

        <xp:dominoView var="view1" viewName="Reserved"></xp:dominoView>
        <xp:table >
        <xp:repeat id="repeat1" rows="30" value="#{view1}"
            var="rowData" indexVar="rowIndex">
                    <xp:text escape="true" id="computedField1"
                    <xp:text escape="true" id="computedField2"

Jun 7, 2018, 10:06 AM
298 Posts
That is up to you...
The repeat does not have sorting, it displays the data in whatever order your data is in.

So, you would have to develop your own sorting that will sort the data and redisplay the repeat control. Typically I get the data for the repeat via code and send an ArrayList of objects to the repeat (not a view). I suspect you would have to do that.

Jun 9, 2018, 3:06 PM
11 Posts

Thanks Howard !!