Company Events Academic NI Developer Zone Support Solutions Products & Services Contact NI MyNI

Property: OrderBy for Condition <DataFinder>

DIAdem 2011 Help

Edition Date: July 2011

Part Number: 370859J-01

»View Product Info

Specifies the Sorting order of the search results when searching with the DataFinder.

Object.OrderBy
ObjectCondition <DataFinder>
Object with this property
Object.OrderByEnumeration with read and write access and the following selection terms:
0eNoOrderBy  
1eOrderByAscending  
2eOrderByDescending  
Note  The DataFinder can only order by base properties and optimized custom properties.
Note  The search is slowed down if the query requests the search results ordered.

The following example generates an extended search for channels and sorts the search results in descending order after the first search condition:

Dim oMyDataFinder, oMyQuery, oMyOrderedCondition
Set oMyDataFinder = Navigator.ConnectDataFinder("My DataFinder")
Set oMyQuery = oMyDataFinder.CreateQuery(eAdvancedQuery)
oMyQuery.ReturnType = eSearchChannel
Call oMyQuery.Conditions.Add(eSearchChannel, "maximum", "<", 1.5)
Call oMyQuery.Conditions.Add(eSearchChannelGroup, "description", "=", "Test Data")
Set oMyOrderedCondition = oMyQuery.Conditions(1)
oMyOrderedCondition.OrderBy = eOrderByDescending 
Call oMyDataFinder.Search(oMyQuery)


 

Your Feedback! poor Poor  |  Excellent excellent   Yes No
 Document Quality? 
 Answered Your Question? 
Add Comments 1 2 3 4 5 submit