[]
        
(Showing Draft Content)

License User Controls

.NET allows creation of user controls and class libraries, reusable components that can be built in one project and consumed by other applications.

When a ComponentOne control is used within a user control or class library, the final application must be properly licensed. In certain scenarios, the user control or library must also include its own runtime license to prevent licensing errors at runtime.

This topic describes the supported licensing approaches for both:

  • MESCIUS License Manager.sa3licx

  • GCLM.gclicx

Choose the Appropriate Licensing Approach

Use the table below to determine the correct approach:

Scenario

Recommended Approach

User control is always used by a known application

Strong-name signing

Application name is known at build time

Generate runtime license for the user control

Application name is unknown (plugin scenario)

Plugin licensing

Option 1: Use Strong-Name Signing

If the user control (or class library) is signed with the same strong-name key as the host application:

  • The application’s runtime license is shared with the user control

  • No separate runtime license file is required

  • The same ComponentOne product licenses must be valid for both projects

This approach is recommended when the user control is always deployed with a known application.

Configure Strong-Name Signing

In Visual Studio:


1 . Open Project Properties for both:

* User control project

* Main application project

2 . Go to the Signing tab

3 . Enable signing and select the same strong-name key file

After building on an activated machine:

  • MESCIUS License Manager: .sa3licx is generated and embedded

  • GCLM: .gclicx is generated and embedded

The user control automatically uses the application license at runtime.

Option 2: Generate a Runtime License for the User Control

Use this approach when:

  • Strong-name signing cannot be used

  • The application name is known at build time

A runtime license must be generated for the user control using a combined name:

<ApplicationName>.<LibraryName>.dll

Example:

MyApplication.MyUserControl.dll

Generate Runtime License Using Visual Studio

MESCIUS License Manager

1 . Go to:

Tools > MESCIUS > MESCIUS License Manager

2 . Click Create RunTime License

3 . Select Custom

4 . Enter:

MyApplication.MyUserControl.dll

5 . Select the licensed product

6. Generate the license


Output:

.sa3licx

GCLM

1 . Go to:

Tools > MESCIUS > License Manager > Create Run-time License

2 . Select Custom

3. Enter:

MyApplication.MyUserControl.dll

4 . Select the licensed product

5. Generate the license


Output:

.gclicx

Embed the Runtime License

1 . Add the generated file to the user control project (typically under Properties)

2. Set:

Build Action = Embedded Resource

Generate Runtime License Using Command Line

MESCIUS License Manager (SA3 Client)

sa3client "<product-id>" -lc ./MyUserControl.sa3licx "MyApplication.MyUserControl.dll"

GCLM

Windows

C:\ProgramData\GrapeCity\gclm\gclm.exe "<product-id>" -lc ./.gclicx "MyApplication.MyUserControl.dll"

Linux / macOS

gclm "<product-id>" -lc ./.gclicx "MyApplication.MyUserControl.dll"

Option 3: Licensing for Unknown Applications (Plugin Scenario)

Use this approach when:

  • The user control is used by unknown or third-party applications

  • The application name is not known at build time

  • Strong-name signing cannot be used

A plugin license is required.

Generate Plugin Runtime License

In this case, generate the license using only the library name:

MyUserControl.dll

Command Line

MESCIUS License Manager

sa3client "<product-id>" -lc ./MyUserControl.sa3licx "MyUserControl.dll"

GCLM

Windows

C:\ProgramData\GrapeCity\gclm\gclm.exe "<product-id>" -lc ./.gclicx "MyUserControl.dll"

Linux / macOS

gclm "<product-id>" -lc ./.gclicx "MyUserControl.dll"

Visual Studio

1 . Go to:

Tools > MESCIUS > License Manager > Create Run-time License

2 . Select Custom

3. Enter:

MyUserControl.dll

4 . Select the plugin-licensed product

5. Generate the license

6. Add the file to the project and set:

Build Action = Embedded Resource

To obtain a plugin license, contact our support team.

Note

Some legacy workflows use older licensing tools. These scenarios are documented separately to avoid confusion with modern licensing flows.