These snippets demonstrate how to apply and manage licenses for Aspose.TeX for .NET. Learn different ways to set up licensing: from file, from stream, metered licensing, and how to clear a license.
- Apply license from file
- Apply license from stream
- Set up metered licensing (pay-as-you-go)
- Clear previously installed license
- Reference Aspose.TeX for .NET: Aspose.TeX on Windows; Aspose.TeX.Drawing on non‑Windows.
- Copy a snippet into your project.
- Obtain a license file or metered keys from Aspose Purchase or get a temporary license.
- Build and run.
Without a valid license, Aspose.TeX for .NET operates in evaluation mode with limitations:
- Maximum 1 page for document typesetting
- Watermarks on output
- Limited functionality
Apply a license to unlock full features.
More about licensing:
- Documentation – Aspose.TeX for .NET
- Product page – Aspose.TeX for .NET
- Free Support Forum – Aspose.TeX
- Purchase License
- Temporary License
- API Reference – Aspose.TeX for .NET
- .NET 6.0+, .NET Core, or .NET Framework
- Aspose.TeX for .NET library
- Valid license file or metered keys (for production use)
Load and apply a license from a .lic file stored on disk. This is the most common way to license Aspose.TeX.
Use Case: Standard licensing for desktop applications or server deployments where the license file is stored locally.
Load and apply a license from a Stream object. Useful when the license file is embedded as a resource or retrieved from a database or cloud storage.
Use Case: Applications where the license is not stored as a physical file, such as embedded resources or cloud-based storage.
Configure metered (pay-as-you-go) licensing by providing public and private keys. With metered licensing, you're charged based on actual API usage.
Key Features:
- Pay-per-Use: Only pay for what you actually process
- No Upfront Costs: No need to purchase a full license upfront
- Usage Tracking: Monitor your API consumption
- Flexible Scaling: Automatically scales with your needs
Use Case: Applications with variable or unpredictable usage patterns, SaaS platforms, or when you want to minimize upfront licensing costs.
How to Get Metered Keys:
- Visit Aspose Purchase
- Select the "Metered License" option
- Obtain your public and private keys
- Use
Metered.SetMeteredKey()to activate
Remove a previously installed license to return to evaluation mode. Useful for testing or when switching between different licenses.
Use Case: Development/testing scenarios where you need to verify evaluation mode behavior, or when temporarily disabling licensing.