Deletes a site from the registry.
Syntax
DWORD WpDeleteSite( LPTSTR szSiteName );
Parameters
- szSiteName
- Posting site name.
Return Value
Returns one of the following values:
NO_ERROR Successful E_INVALIDARG One of the arguments is invalid. WEBPOST_ERROR_DELETE_SITE An error occurred while the Web Publishing API was deleting the requested site. WEBPOST_ERROR_EXTENDED_ERROR A Web Publishing extended error occurred. This means that the API received an error code that the API client may not be able to translate, so the API performed the translation and cached the error message for retrieval on a call to the WpGetErrorString method. WEBPOST_ERROR_INIT_FAILED An error occurred while attempting to initialize the Web Publishing API DLL. WEBPOST_ERROR_NO_EXT_ERROR_INFO An extended error occurred in the Web Publishing API, but the error message could not be retrieved. WEBPOST_ERROR_PROV_EP The Web Publishing API could not locate a required entry point in one of its service providers. WEBPOST_ERROR_SITE_DOESNOTEXIST The Web Publishing API could not delete the requested site because no site with the specified name exists.
Remarks
WpDeleteSite calls WppDeleteSite on the provider that owns the specified site.
Example
The following example calls WpDeleteSite to delete a site called site1 from the registry.
{ HRESULT hResult = NOERROR; hResult = WpDeleteSite("site1"); }
Function Information
Windows NT Use version 4.0 and later Windows Use Windows 95 and later Header Declared in Wpapi.h Import Library Link with WebPost.lib Minimum availability Internet Explorer 4.0