0

I have some SSJS that does a FTSearch on a view and I get a viewEntryCollection returned:

var veCol:NotesViewEntryCollection = thisAppDB.getView("vwFTSearch").getAllEntries()
veCol.FTSearch(queryString);
viewScope.vsColCount = veCol.getCount();

I know that veCol contains the viewEntries that I want and they are in the correct order. Now I would like to define a dataSource that I will use as the dataSource for a repeat control. I think the answer involves creating an Object Data Source but I can not find any documentation on how to do this. Any pointers greatly appreciated.

Bill F
  • 2,057
  • 3
  • 18
  • 39

1 Answers1

3

You can use your view entry collection as input for a repeat by doing this:

<xp:repeat id="repeat1" var="rowEntry" removeRepeat="true">
    <xp:this.value><![CDATA[#{javascript:
        var veCol:NotesViewEntryCollection = thisAppDB.getView("vwFTSearch").getAllEntries()
        veCol.FTSearch(queryString);
    }]]></xp:this.value>
    <!-- add elements to be repeated here -->
</xp:repeat>
Per Henrik Lausten
  • 21,331
  • 3
  • 29
  • 76