Export (0) Print
Expand All
Expand Minimize
This topic has not yet been rated - Rate this topic

IUIAutomation::CreateOrCondition method

Creates a combination of two conditions where a match exists if either of the conditions is true.

Syntax


HRESULT CreateOrCondition(
  [in]           IUIAutomationCondition *condition1,
  [in]           IUIAutomationCondition *condition2,
  [out, retval]  IUIAutomationCondition **newCondition
);

Parameters

condition1 [in]

Type: IUIAutomationCondition*

A pointer to the first condition.

condition2 [in]

Type: IUIAutomationCondition*

A pointer to the second condition.

newCondition [out, retval]

Type: IUIAutomationCondition**

Receives a pointer to the combined condition.

Return value

Type: HRESULT

If this method succeeds, it returns S_OK. Otherwise, it returns an HRESULT error code.

Remarks

The CreateOrCondition method calls AddRef on the condition1 and condition2 pointers. This means you can call Release on those two pointers after the call to CreateOrCondition returns without invalidating the pointer returned from CreateOrCondition. When you call Release on the pointer returned from CreateOrCondition, UI Automation calls Release on the condition1 and condition2 pointers.

Requirements

Minimum supported client

Windows 7, Windows Vista with SP2 and Platform Update for Windows Vista, Windows XP with SP3 and Platform Update for Windows Vista [desktop apps only]

Minimum supported server

Windows Server 2008 R2, Windows Server 2008 with SP2 and Platform Update for Windows Server 2008, Windows Server 2003 with SP2 and Platform Update for Windows Server 2008 [desktop apps only]

Header

UIAutomationClient.h (include UIAutomation.h)

IDL

UIAutomationClient.idl

See also

Reference
CreateOrConditionFromArray
CreateOrConditionFromNativeArray
FindAll
FindAllBuildCache
FindFirst
FindFirstBuildCache
IUIAutomation
IUIAutomationCondition

 

 

Did you find this helpful?
(1500 characters remaining)
Thank you for your feedback

Community Additions

ADD
Show:
© 2014 Microsoft. All rights reserved.