ISceSvcAttachmentData::Initialize method (scesvc.h)

The Initialize method informs the Security Configuration snap-in that the snap-in extension is loaded, and it establishes a context for communications.

Syntax

HRESULT Initialize(
  [in]  LPCTSTR                       lpServiceName,
  [in]  LPCTSTR                       lpTemplateName,
  [in]  LPSCESVCATTACHMENTPERSISTINFO lpSceSvcPersistInfo,
  [out] SCESVC_HANDLE                 *pscesvcHandle
);

Parameters

[in] lpServiceName

String that specifies the name of the security service to retrieve information about.

[in] lpTemplateName

String that specifies the name of the template.

[in] lpSceSvcPersistInfo

Pointer to the ISceSvcAttachmentPersistInfo interface of the attachment snap-in extension.

[out] pscesvcHandle

Pointer that receives an SCESVC_HANDLE that represents the communication context between the Security Configuration snap-in and the snap-in extension. This handle is passed in as a parameter to the other ISceSvcAttachmentData methods. When the attachment snap-in extension no longer needs this handle, free it by calling ISceSvcAttachmentData::CloseHandle.

Return value

The return value is an HRESULT. A value of S_OK indicates the method was successful.

Requirements

Requirement Value
Minimum supported client Windows XP [desktop apps only]
Minimum supported server Windows Server 2003 [desktop apps only]
Target Platform Windows
Header scesvc.h
DLL Wsecedit.dll

See also

ISceSvcAttachmentData

ISceSvcAttachmentData::CloseHandle

ISceSvcAttachmentPersistInfo

SCESVC_HANDLE