# Licensing .NET Framework Applications

## Content

This topic applies to licensing **.NET Framework 4.6.2 and later** applications that use ComponentOne **WinForms, <span data-testid="definition-highlighter" class="_5pioz8co _189e1dm9 _1il9buyh _19lc184f _d0altlke" style="border-image: linear-gradient(90deg, rgb(0, 101, 255), rgb(191, 99, 243), rgb(245, 230, 168)) 0 0 100% / 1 / 0 stretch; border-width: 0px 0px 2px; border-bottom-style: solid; --_11qfq0e: solid;">WPF</span>, and ASP.NET Web Forms** controls.
For older ComponentOne versions, see **[Licensing Older .NET Framework Applications](https://developer.mescius.com/componentone/docs/license/online-license/licensing-applications/licensing-old-net-framework-applications "https://developer.mescius.com/componentone/docs/license/online-license/licensing-applications/licensing-old-net-framework-applications")**.
For other application types, see **[Licensing Applications](https://developer.mescius.com/componentone/docs/license/online-license/licensing-applications "https://developer.mescius.com/componentone/docs/license/online-license/licensing-applications")**.

## Overview

To build and properly license a .NET Framework application, the machine performing the build must have an activated ComponentOne serial key.
After activation, licensing is handled automatically by Visual Studio and the ComponentOne build process. Understanding how design-time and run-time license files are generated can help you verify licensing and troubleshoot issues.
For instructions on activating a serial key, see **[Activating a Serial Key](https://developer.mescius.com/componentone/docs/license/online-license/activating-serial-key "https://developer.mescius.com/componentone/docs/license/online-license/activating-serial-key")**.
 

## Design-Time Licensing (licenses.licx)

ComponentOne .NET Framework controls use the standard **licenses.licx** mechanism supported by the Microsoft .NET `LicenseProvider`.

### Automatic Generation

When you add a ComponentOne control to the Visual Studio designer surface:

* A **licenses.licx** file is generated in the project
* The file includes the fully qualified component names and version information
* The file must remain in sync with the referenced component versions

### Manually Generate the licenses.licx File

If controls are added through code or <span data-testid="definition-highlighter" class="_5pioz8co _189e1dm9 _1il9buyh _19lc184f _d0altlke" style="border-image: linear-gradient(90deg, rgb(0, 101, 255), rgb(191, 99, 243), rgb(245, 230, 168)) 0 0 100% / 1 / 0 stretch; border-width: 0px 0px 2px; border-bottom-style: solid; --_11qfq0e: solid;">XAML</span> instead of the designer, the **licenses.licx** file may not be generated automatically.
In these cases, you can create or update the **licenses.licx** file manually to ensure the application compiles and licenses correctly.
For step-by-step instructions, see **[Generate licenses.licx File Manually](https://developer.mescius.com/componentone/docs/license/online-license/common-licensing-scenarios/generate-license-file-manually "https://developer.mescius.com/componentone/docs/license/online-license/common-licensing-scenarios/generate-license-file-manually")**.

### Update an Existing licenses.licx File

You can update or regenerate the file using the Visual Studio extension:

1. In Visual Studio, select **Tools > MESCIUS > Update Projects**
2. The tool scans the project and updates the **licenses.licx** file as needed

## Run-Time Licensing

When the application is built on a machine with an activated serial key, a unique run-time license file is generated and embedded with the application.

### Run-Time License File

* The run-time license file is typically named **.sa3licx**
* In some mixed or legacy scenarios, a **.gclicx** file may also be generated (for example, when legacy support is enabled)
* The file is generated during the build and embedded as a resource

Before embedding, the license file can usually be found in the build output folder, such as:

* `obj/Debug`
* `obj/Release`

The run-time license file **must be distributed with the application** as an embedded resource.

## Troubleshooting

If you encounter unlicensed nag screens or licensing errors at runtime, see: [Troubleshooting](https://developer.mescius.com/componentone/docs/license/online-license/Troubleshooting "https://developer.mescius.com/componentone/docs/license/online-license/Troubleshooting").