and just compile in with the project. The problem is that Aspose.Pdf is not a component, and the compiler I'm using (Delphi) doesn't seem to like it. Has anyone embedded a license on an application?
BTW, Why isn't the Pdf object derived from System.ComponentModel.Component?
That way it could be used on forms as a non-visual component.
Thank you for considering Aspose.Pdf.
Here is an example about using embeded license:
(First add the license file into your project as embeded resource)
Assembly assembly = Assembly.GetCallingAssembly();
string resourceNames = assembly.GetManifestResourceNames();
Stream licStream = null;
foreach (string resourceName in resourceNames)
if (resourceName.IndexOf("Aspose.Custom.lic") != -1)
licStream = assembly.GetManifestResourceStream(resourceName);
if(licStream == null)
throw new ApplicationException("load license error!");
License lic = new License();
Thank you. Works perfectly now.