SetLicense
Leave feedback
On this page
Licenses the component.
public void SetLicense(Stream licenseStream)
| Parameter | Type | Description |
|---|---|---|
| licenseStream | Stream | The license stream. |
| exception | condition |
|---|---|
| ArgumentNullException | Thrown when licenseStream is null. |
The following example demonstrates how to set a license passing Stream of the license file.
using (FileStream licenseStream = File.OpenRead("GroupDocs.Markdown.lic"))
{
License license = new License();
license.SetLicense(licenseStream);
}
- class License
- namespace GroupDocs.Markdown
- assembly GroupDocs.Markdown
Licenses the component.
public void SetLicense(string licensePath)
| Parameter | Type | Description |
|---|---|---|
| licensePath | String | The license file path. |
| exception | condition |
|---|---|
| ArgumentException | Thrown when licensePath is null or empty string. |
The following example demonstrates how to set a license passing a path to the license file.
string licensePath = "GroupDocs.Markdown.lic";
License license = new License();
license.SetLicense(licensePath);
- class License
- namespace GroupDocs.Markdown
- assembly GroupDocs.Markdown
Was this page helpful?
Any additional feedback you'd like to share with us?
Please tell us how we can improve this page.
Thank you for your feedback!
We value your opinion. Your feedback will help us improve our documentation.