Compartilhar via


IOleComponent2.GetWaitHandlesAndTimeout Method

Definition

When overridden in a derived class, returns the time-out and the list of handles on which this component is waiting.

public:
 int GetWaitHandlesAndTimeout([Runtime::InteropServices::Out] cli::array <IntPtr> ^ % aHandles, [Runtime::InteropServices::Out] System::UInt32 % pnHandles, [Runtime::InteropServices::Out] System::UInt32 % pdwTimeout, IntPtr pvLoopData);
public int GetWaitHandlesAndTimeout (out IntPtr[] aHandles, out uint pnHandles, out uint pdwTimeout, IntPtr pvLoopData);
abstract member GetWaitHandlesAndTimeout : IntPtr[] * uint32 * uint32 * nativeint -> int
Public Function GetWaitHandlesAndTimeout (ByRef aHandles As IntPtr(), ByRef pnHandles As UInteger, ByRef pdwTimeout As UInteger, pvLoopData As IntPtr) As Integer

Parameters

aHandles

IntPtr[]

nativeint[]

When this method returns, contains an array of object handles for which this component is waiting, passed by reference. Must return at least one and no more than 64 handles. Must not return duplicate handles.

pnHandles
UInt32

When this method returns, contains the number of handles in aHandles.

pdwTimeout
UInt32

When this method returns, contains the time-out in milliseconds, or 0xFFFFFFFF for an infinite time-out.

pvLoopData
IntPtr

nativeint

The object that was passed in pvLoopData when FPushMessageLoop(UInt32, UInt32, IntPtr) was called for this component.

Returns

An error code (HRESULT) value that indicates the status of the operation.

Remarks

When one of the handles is signaled, the IOleComponentManager calls OnHandleSignaled. If the time-out expires before a handle is signaled, IOleComponentManager calls OnTimeout.

This method is called on the same thread as the FPushMessageLoop method was called on when this component was added to the message loop.

Applies to