Sets the license for the calling application.
#include "ltms.h"
Language | Syntax |
---|---|
C | HRESULT IltmsLicenseManager_SetLicense(pLicenseManager, license, key, flags) |
C++ | HRESULT SetLicense(license, key, flags) |
Pointer to an IltmsLicenseManager interface.
String containing the license or a path to the license file.
String containing the key or a path to the key file.
Flags that specify the type of operation to perform. It is a bitwise OR of the ltmsSetLicenseFlags Enumeration Constants.
Value | Meaning |
---|---|
S_OK | The function was successful. |
<> S_OK | An error occurred. Refer to the Error Codes or the HRESULT error codes in the DirectShow documentation. |
This function will set the license for the entire application, and is only required to be called once. If the library is already licensed, any additional calls to this function will be ignored, unless ltmsSetLicenseFlags_Overwrite is specified.
Win32, x64.
For a C++ example, refer to License Holder Example for C++.