I am getting the following error when I attempt to create an assembly which uses Aspose.Pdf.
Hi Norm,
Hi Norm,
Similar problem with Aspose.PDF 18.5 and Microsoft SQL Server 2017 14.0.2002.14 (X64)
CREATE ASSEMBLY [System.Drawing] FROM ‘C:\Windows\Microsoft.NET\Framework64\v4.0.30319\System.Drawing.dll’
WITH PERMISSION_SET = UNSAFE
CREATE ASSEMBLY [Aspose.PDF] FROM ‘C:.…\Aspose.PDF.dll’ WITH PERMISSION_SET = UNSAFE
works fine and ends up with the following assemblies loaded:
- Aspose.PDF
- Microsoft.Build.Tasks.v4.0
- System.Runtime.Caching
- System.Xaml
- Microsoft.Build.Framework
- Microsoft.Build.Utilities.v4.0
- SMDiagnostics
- System.ServiceModel.Internals
- System.Runtime.Serialization
- System.Configuration.Install
- System.ServiceProcess
- System.DirectoryServices.Protocols
- System.ComponentModel.DataAnnotations
- System.Web.ApplicationServices
- System.Drawing.Design
- Accessibility
- System.Windows.Forms
- System.Design
- System.Web.RegularExpressions
- System.Runtime.Serialization.Formatters.Soap
- System.Runtime.Remoting
- System.EnterpriseServices
- System.DirectoryServices
- System.Web
- System.Drawing
Error is inside Aspose.PDF.Page.ConvertToPNGMemoryStream()
Stack trace:
at System.Reflection.RuntimeAssembly._nLoad(AssemblyName fileName, String codeBase, Evidence assemblySecurity, RuntimeAssembly locationHint, StackCrawlMark& stackMark, IntPtr pPrivHostBinder, Boolean throwOnFileNotFound, Boolean forIntrospection, Boolean suppressSecurityChecks)
at System.Reflection.RuntimeAssembly.InternalLoadAssemblyName(AssemblyName assemblyRef, Evidence assemblySecurity, RuntimeAssembly reqAssembly, StackCrawlMark& stackMark, IntPtr pPrivHostBinder, Boolean throwOnFileNotFound, Boolean forIntrospection, Boolean suppressSecurityChecks)
at System.Reflection.RuntimeAssembly.InternalLoad(String assemblyString, Evidence assemblySecurity, StackCrawlMark& stackMark, IntPtr pPrivHostBinder, Boolean forIntrospection)
at System.Reflection.RuntimeAssembly.InternalLoad(String assemblyString, Evidence assemblySecurity, StackCrawlMark& stackMark, Boolean forIntrospection)
at System.Reflection.Assembly.Load(String assemblyString)
at ..(String ) at ..() at .(Object , ResolveEventArgs )
at System.AppDomain.OnResourceResolveEvent(RuntimeAssembly assembly, String resourceName)
at System.Reflection.RuntimeAssembly.GetResource(RuntimeAssembly assembly, String resourceName, UInt64& length, StackCrawlMarkHandle stackMark, Boolean skipSecurityCheck)
at System.Reflection.RuntimeAssembly.GetManifestResourceStream(String name, StackCrawlMark& stackMark, Boolean skipSecurityCheck)
at System.Reflection.RuntimeAssembly.GetManifestResourceStream(String name)
at .(String , String , Assembly ) at .(String ) at .() at .() at .() at .( & )
at Aspose.Pdf.Devices.ImageDevice.(Page )
at Aspose.Pdf.Devices.PngDevice.Process(Page page, Stream output)
at Aspose.Pdf.Facades.PdfConverter.(Page )
at Aspose.Pdf.Page.ConvertToPNGMemoryStream()
at UserDefinedFunctions.PDFToPNG(String pdfInfo, Byte[] document)
@syork.spitfiremanage
Thank you for contacting support.
Would you please upgrade to Aspose.PDF for .NET 19.1 and then share your kind feedback with us. In case the issue persists, please share narrowed down sample application and DLL file of your project while mentioning the steps to reproduce the issue.
Here is the stack from Aspose.PDF 19.1Aspose CLR.zip (373.7 KB)
The attached ZIP contains the VB2017 SQL SLR Project, deployment script and test script.
You will find references to a competitors PDF tool that WORKS PERFECTLY in the SQL CLR deployment.
test[1] - System.IO.FileNotFoundException: Could not load file or assembly ‘zx_bc86ffd0089c4489b2f8c9603ae5ebbd, PublicKeyToken=716fcc553a201e56’ or one of its dependencies.
The system cannot find the file specified. File name: ‘zx_bc86ffd0089c4489b2f8c9603ae5ebbd, PublicKeyToken=716fcc553a201e56’
at System.Reflection.RuntimeAssembly._nLoad(AssemblyName fileName, String codeBase, Evidence assemblySecurity, RuntimeAssembly locationHint, StackCrawlMark& stackMark, IntPtr pPrivHostBinder, Boolean throwOnFileNotFound, Boolean forIntrospection, Boolean suppressSecurityChecks)
at System.Reflection.RuntimeAssembly.InternalLoadAssemblyName(AssemblyName assemblyRef, Evidence assemblySecurity, RuntimeAssembly reqAssembly, StackCrawlMark& stackMark, IntPtr pPrivHostBinder, Boolean throwOnFileNotFound, Boolean forIntrospection, Boolean suppressSecurityChecks)
at System.Reflection.RuntimeAssembly.InternalLoad(String assemblyString, Evidence assemblySecurity, StackCrawlMark& stackMark, IntPtr pPrivHostBinder, Boolean forIntrospection)
at System.Reflection.RuntimeAssembly.InternalLoad(String assemblyString, Evidence assemblySecurity, StackCrawlMark& stackMark, Boolean forIntrospection)
at System.Reflection.Assembly.Load(String assemblyString)
at #=qppcp$UOnRECkeWE3qESNUApMH7_fLrhs0XxzrvrVSxg=.#=zTT0v9ASec2gfj6tqBATHmqyAqlRw.#=z3orNgcmwViYu0Y6zVrYrQ208m1ib(String #=zqmN5Q6TjqGioSfeJ35om2zmCzDfQ)
at #=qppcp$UOnRECkeWE3qESNUApMH7_fLrhs0XxzrvrVSxg=.#=zTT0v9ASec2gfj6tqBATHmqyAqlRw.#=zRgacOPyKqL8ulFoYIHLAa8d4myva()
at #=qppcp$UOnRECkeWE3qESNUApMH7_fLrhs0XxzrvrVSxg=.#=zsrKmhxd501NvFsSVQvDzVMccI6B6(Object #=zylMvDJ0wtYYILKfGF5sng1cGkoby, ResolveEventArgs #=zWtO3_sdk3hGSWT7uRhIUAZI=)
at System.AppDomain.OnResourceResolveEvent(RuntimeAssembly assembly, String resourceName)
at System.Reflection.RuntimeAssembly.GetResource(RuntimeAssembly assembly, String resourceName, UInt64& length, StackCrawlMarkHandle stackMark, Boolean skipSecurityCheck)
at System.Reflection.RuntimeAssembly.GetManifestResourceStream(String name, StackCrawlMark& stackMark, Boolean skipSecurityCheck)
at System.Reflection.RuntimeAssembly.GetManifestResourceStream(String name)
at #=ztypmhx77HtZ1LLS5vC1gIpf70I$v.#=zewJ8R15YnfLy(String #=zEE6qDds=, String #=zXUnKFmE=, Assembly #=z96erTAk=)
at #=z0dASLN7wQOsq_z9Dj5SsjND1ZtldTzxRQVTFvXU=.#=zeeFUA9B6xs9V(String #=zX4s$gLA=)
at #=z0dASLN7wQOsq_z9Dj5SsjND1ZtldTzxRQVTFvXU=.#=z4tg2u3rA6FJb()
at #=z0dASLN7wQOsq_z9Dj5SsjND1ZtldTzxRQVTFvXU=.#=zZl82nPT$vcKa()
at #=z0dASLN7wQOsq_z9Dj5SsjND1ZtldTzxRQVTFvXU=.#=zZd9S3Yw=()
at #=zPVWVjCyah_TMHUWViTXz62LTIxew.#=zhBRLJYE=(#=zK0Zae2nT9grrdestLRwNBCgRmpsSL8R2ORSIRuKbDFtA& #=zmrHx47E=)
at Aspose.Pdf.Devices.ImageDevice.#=zhBRLJYE=(Page #=zfvoEoF8=)
at Aspose.Pdf.Devices.PngDevice.Process(Page page, Stream output)
at Aspose.Pdf.Facades.PdfConverter.#=zchpYpsNHqlJd4fk2Nw==(Page #=zfvoEoF8=)
at Aspose.Pdf.Page.ConvertToPNGMemoryStream()
at UserDefinedFunctions.PDFToPNG(String pdfInfo, Byte[] document)
Thank you for sharing respective data.
We have recorded your concerns and have logged a ticket with ID PDFNET-45876 in our issue management system for further investigations and resolution. We will let you know as soon as some significant updates will be available in this regard.