Microsoft DirectX 8.1 (C++) |
This topic applies to Windows XP Home Edition and Windows XP Professional only.
The Cond property retrieves a newly created MetaPropertyCondition object. This MetaPropertyCondition object can be used with other MetaPropertyCondition objects in relational and logical evaluations.
Syntax
objMetaPropertyType.Type(
strCond As String,
lang As Long,
value) As MetaPropertyType
Parameters
strCond
[in] Specifies the desired comparison. This parameter must be one of the following strings.
Value | Description |
= | Equal. |
!= or <> | Not equal. |
< | Less than. |
<= | Less than or equal. |
> | Greater than. |
>= | Greater than or equal. |
LIKE | Matching character pattern. For more information, see the Microsoft SQL Server documentation. |
NOT LIKE | Nonmatching character pattern. |
lang
[in] Specifies the language of the MetaProperty object on which to base the condition.
value
[in] Specifies the value of the MetaProperty object on which to base the condition. See Remarks.
Error Codes
If the property fails, an error is raised and Err.Number is set to a value other than zero.
Return Values
This property returns a MetaPropertyCondition object.
Remarks
This property can be used instead of MetaProperty.Cond to create a condition based on a metaproperty that does not exist. Internally, this property uses this MetaPropertyType object plus the specified language and value to create a temporary MetaProperty object. The Cond property of the temporary MetaProperty object is then used to create a new MetaPropertyCondition object. It is this MetaPropertyCondition object that is returned.
In VBScript, if value is a string, it must be passed as a string literal, as in the following example:
Set mycond = mytype.cond("LIKE" ,0, cstr(searchstring))
See Also