EPiServer: PropertyCriteria — GreaterThan Value or Value GreaterThan?

by Stephen Horsfield 18. January 2008 14:15

Overview

Using EPiServer, you may use the FindPagesWithCriteria method to retrieve a list of pages based on certain properties, but the helpfully enumerated conditions may be confusing.  After all, with a binary inequality operator it is quite important to know the order of the expressions...

Context

You use PropertyCriteria objects to set the criteria for a search and you can use the Condition property to determine the operator.  Suppose you selected the GreaterThan operator:

IF --PROPERTY-- > --VALUE-- THEN

But is it actually:

IF --VALUE-- > --PROPERTY-- THEN

The two operations give entirely different answers, and they are not even inverse.  The inverse operator to > (greater-than) is <= (less-than-or-equal).

The answer

A search through the EPiServer documentation reveals that the answer is that EPiServer will use:

IF --PROPERTY-- --CONDITION-- --VALUE-- THEN

Versions

Metadata

Tags:

ASP.NET | EPiServer | Software Development

Powered by BlogEngine.NET 1.5.0.7
Theme by Interakting

Interakting

A full service digital agency offering online strategy, design and usability, systems integration and online marketing services that deliver real business benefits and ensure your online objectives are met.

Calendar

<<  February 2012  >>
MoTuWeThFrSaSu
303112345
6789101112
13141516171819
20212223242526
2728291234
567891011

View posts in large calendar