HrCreateOfflineObj
Aplica-se a: Outlook 2013 | Outlook 2016
Cria um objeto offline MAPI que é usado pelo provedor e pelo repositório para notificar MAPI quando o objeto fica online e offline,
Propriedade | Valor |
---|---|
Exportado por: |
Msmapi32.dll |
Implementado por: |
Outlook |
Chamado por: |
Cliente |
STDAPI HrCreateOfflineObj(
ULONG ulFlags,
MAPIOFFLINE_CREATEINFO* pCreateInfo,
IMAPIOfflineMgr** ppOffline
);
Parâmetros
ulFlags
[in] Deve ser 0.
pCreateInfo
[in] Um ponteiro para uma estrutura MAPIOFFLINE_CREATEINFO que contém as informações necessárias para criar o objeto offline.
ppOffline
[out] Um ponteiro para a interface IMAPIOfflineMgr .
Valor de retorno
Nenhuma.
HrOpenOfflineObj
Exemplo
// create/get global offline object to use as parent.
ZeroMemory(&OfflineCreateInfo, sizeof(OfflineCreateInfo));
OfflineCreateInfo.ulSize = sizeof(OfflineCreateInfo);
OfflineCreateInfo.ulCreateFlags = 0;
OfflineCreateInfo.pwszProfileName = pszProfileName;
OfflineCreateInfo.ulCapabilities = ulCapabilities;
OfflineCreateInfo.pGUID = &GUID_GlobalState;
OfflineCreateInfo.pInstance = NULL;
OfflineCreateInfo.pParent = NULL;
OfflineCreateInfo.pMAPISupport = NULL;
OfflineCreateInfo.pAggregateInfo = NULL;
OfflineCreateInfo.pConnectInfo = NULL;
// Create an offline object for the provider with global as parent.
ZeroMemory(&OfflineCreateInfo, sizeof(OfflineCreateInfo));
OfflineCreateInfo.ulSize = sizeof(OfflineCreateInfo);
OfflineCreateInfo.ulCreateFlags = 0;
OfflineCreateInfo.pwszProfileName = pszProfileName;
OfflineCreateInfo.ulCapabilities = ulCapabilities;
OfflineCreateInfo.pGUID = pGuid;
OfflineCreateInfo.pInstance = pInstance;
OfflineCreateInfo.pParent = pGlobalOfflineMgr;
OfflineCreateInfo.pMAPISupport = NULL;
OfflineCreateInfo.pAggregateInfo = NULL;
OfflineCreateInfo.pConnectInfo = NULL;
// create store offline object which aggregates with the store object and has provider offline object as parent.
ZeroMemory(&OfflineCreateInfo, sizeof(OfflineCreateInfo));
OfflineCreateInfo.ulSize = sizeof(OfflineCreateInfo);
OfflineCreateInfo.ulCreateFlags = 0;
OfflineCreateInfo.pwszProfileName = pszProfileName;
OfflineCreateInfo.ulCapabilities = ulCapabilities;
OfflineCreateInfo.pGUID = NULL;
OfflineCreateInfo.pInstance = NULL;
OfflineCreateInfo.pParent = m_pProviderOfflineMgr;
OfflineCreateInfo.pMAPISupport = pMAPISup;
OfflineCreateInfo.pAggregateInfo = &AggregateInfo;
OfflineCreateInfo.pConnectInfo = NULL;
ZeroMemory(&AggregateInfo, sizeof(AggregateInfo));
AggregateInfo.ulSize = sizeof(AggregateInfo);
AggregateInfo.pOuterObj = (IMsgStore *)this;
AggregateInfo.pRefTrackRoot = NULL;