IHWEventHandler::Initialize method

Initializes an object that contains an implementation of the IHWEventHandler interface.

Syntax

HRESULT Initialize(
  LPCWSTR pszParams
);

Parameters

pszParams

Type: LPCWSTR

A pointer to a string buffer that contains the string from the following registry value.

HKEY_LOCAL_MACHINE
   Software
      Microsoft
         Windows
            CurrentVersion
               Explorer
                  AutoPlayHandlers
                     Handlers
                        HandlerName
                           InitCmdLine = string

Return Value

Type: HRESULT

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

Remarks

This method receives the registry string stored in the InitCmdLine value under the

     <b>AutoPlayHandlers</b>\<b>Handlers</b>\<i>HandlerName</i>key. Applications that have registered with AutoPlay as event handlers place this string into the registry as part of the registration process.

Requirements

   
Minimum supported client Windows XP [desktop apps only]
Minimum supported server Windows Server 2003 [desktop apps only]
Target Platform Windows
Header shobjidl.h
DLL Shimgvw.dll