Share via


Windows Media Player 11 SDK IWMPQuery::addCondition 

Windows Media Player SDK banner art

Previous Next

IWMPQuery::addCondition

The addCondition method adds a condition to the compound query using AND logic.

Syntax

  HRESULT addCondition(
  BSTR  bstrAttribute,
  BSTR  bstrOperator,
  BSTR  bstrValue
);

Parameters

bstrAttribute

[in]  String containing the attribute name.

bstrOperator

[in]  String containing the operator. See Remarks for supported values.

bstrValue

[in]  String containing the attribute value.

Return Values

The method returns an HRESULT. Possible values include, but are not limited to, those in the following table.

Return code Description
S_OK The method succeeded.

Remarks

Conditions contained in a compound query are organized into condition groups. Multiple conditions within a condition group are always concatenated by using AND logic. Condition groups are always concatenated to each other by using OR logic. To start a new condition group, call IWMPQuery::beginNextGroup.

Compound queries using IWMPQuery are not case sensitive.

A list of values for the bstrAttribute parameter can be found in the Alphabetical Attribute Reference section.

The following table lists the supported values for bstrOperator.

String Applies To
BeginsWith Strings
Contains Strings
Equals All types
GreaterThan Numbers, Dates
GreaterThanOrEquals Numbers, Dates
LessThan Numbers, Dates
LessThanOrEquals Numbers, Dates
NotBeginsWith Strings
NotContains Strings
NotEquals All types

Windows Media Player 10 Mobile: This method is not supported.

Requirements

Version: Windows Media Player 11.

Header: Include wmp.h.

Library: Use wmp.dll.

See Also

Previous Next