Trouble Figuring Out Where to Put the License

I am new to using a license like the one required for the full Aspose.Tasks for Java functionality. No matter where I place the license or when I use setLicense, I am unable to build a project without the evaluation limitations.

I have looked at the documentation and posed/answered questions in the forum, but still am left unable to get the use of my temporary license before it expires in a little more than a week.

My project in built into a Jar, using some external jars/libraries, like Aspose.Tasks. In content of using Aspose.Tasks as an external jar, where do I place the license?

@JRDobry,

Could you please confirm if the license file is accessible to your application? The license file should be placed along side the jar file. You can verify access to the license file by loading it in file stream. If the problem still persists, please create a simple Java project replicating the problem and share with us for further analysis at our end.

I managed to get the license working with the following code snippet::

            com.aspose.tasks.License license = new com.aspose.tasks.License();
license.setLicense("Aspose.Tasks.lic");} catch
    (Exception e) {

However, I still have a problem, as this seems to only work when I utilize the Aspose.Tasks jar as an external source. If I package the Aspose.Tasks jar inside of my Project jar, I can run the classes from Aspose, but they only work with the evaluation limitations.

So, is there a way in which to package the Aspose.Tasks classes and license inside of a single Project jar? Reading the license and setting it from inside of your Project jar?

Figured it out. Even though I was setting the license in my main, I needed to set it before doing anything else to get this working.

@JRDobry,

Its good to know that the issue is resolved. Please feel free to write in case you have any further query related to API.