LicenseSetLicense Method (Stream)
Licenses the component.

Namespace: GroupDocs.Viewer
Assembly: GroupDocs.Viewer (in GroupDocs.Viewer.dll) Version: 21.5
Syntax
public void SetLicense(
	Stream licenseStream
)

Parameters

licenseStream
Type: System.IOStream
The license stream.
Exceptions
ExceptionCondition
ArgumentNullExceptionThrown when licenseStream is null.
Examples
The following example demonstrates how to set a license passing Stream of the license file.
C#
using (FileStream licenseStream = File.OpenRead("GroupDocs.Viewer.lic"))
{
    License license = new License();
    license.SetLicense(licenseStream);
}
See Also