IPreviewHandler::SetFocus method

Directs the preview handler to set focus to itself.

Syntax


HRESULT SetFocus();

Parameters

This method has no parameters.

Return value

Type: HRESULT

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

Remarks

This method should query the state of the SHIFT key to decide whether to set focus to its first tab stop or its last tab stop. This is necessary because the IPreviewHandler::SetFocus can only succeed if the focus is being set to a window created by the calling thread.

This is the extent of accelerator keys coming down from the host to the preview handler; no other accelerators are passed down. IPreviewHandler::TranslateAccelerator is only used for messages from the preview handler's message pump up to the IPreviewHandler object.

Requirements

Minimum supported client

Windows Vista, Windows XP [desktop apps only]

Minimum supported server

Windows Server 2003 [desktop apps only]

Redistributable

Windows Search 4 or later

Header

Shobjidl.h

IDL

Shobjidl.idl

 

 

Show: