System Exception thrown when setting the license

We have an Aspose license that was valid on products released before 20 Aug 2020.
Our application uses .Net. The current version that the application has is aspose 19.7.
When I try to update it to any later package I am getting an exception in the following place
var license = new Aspose.Pdf.License();
license.SetLicense(“Aspose.Total.lic”);

The exception says system exception and the stack trace is not readable.

Any idea?

@dineshknayak,

Are you using .Net Framework? Or .Net Core.

Because there was a change in the licenses(not sure of the exact version) that made old licenses incompatibles with the new version.

To test the new version, you can always request a temporary license(Temporary License - Purchase - aspose.com). But I would not load an older license in a new version of the API.