This example shows how to use the ltmmSupportManager object to unlock support for DVD conversions.
HRESULT ConvertDVDUnlockSupport()
{
VARIANT_BOOL vb;
IltmmSupportManager* pSprtMngr;
HRESULT hr = CoCreateInstance(CLSID_ltmmSupportManager, NULL, CLSCTX_INPROC_SERVER, IID_IltmmSupportManager, (void**)&pSprtMngr);
if (hr != S_OK)
return -1;
pSprtMngr->IsSupportLocked(L_SUPPORT_CONVERTFROMDVD, &vb);
if (vb == VARIANT_TRUE)
{
static TCHAR L_KEY_CONVERTFROMDVD[] = TEXT("DVDKey");
USES_CONVERSION;
hr = pSprtMngr->UnlockSupport(L_SUPPORT_CONVERTFROMDVD, T2OLE(L_KEY_CONVERTFROMDVD));
if (hr != S_OK)
{
pSprtMngr->Release();
return hr;
}
pSprtMngr->IsSupportLocked(L_SUPPORT_CONVERTFROMDVD, &vb);
if (vb != VARIANT_FALSE)
return E_FAIL;
return S_OK;
}
return S_OK;
}
Raster .NET | C API | C++ Class Library | JavaScript HTML5
Document .NET | C API | C++ Class Library | JavaScript HTML5
Medical .NET | C API | C++ Class Library | JavaScript HTML5
Medical Web Viewer .NET