【问题标题】:Aspose Slides Dotnet Core Linux, failing to get thumbnailAspose Slides Dotnet Core Linux,无法获取缩略图
【发布时间】:2022-08-22 17:02:45
【问题描述】:

在 DotnetCore6 Linux 中运行 aspose 幻灯片的基本测试时,我得到:

System.TypeInitializationException : \'Gdip\' 的类型初始化程序引发了异常。 ---- System.PlatformNotSupportedException : System.Drawing.Common 在非 Windows 平台上不受支持。请参阅https://aka.ms/systemdrawingnonwindows 了解更多信息。 堆栈跟踪: 在 System.Drawing.SafeNativeMethods.Gdip.GdipCreateBitmapFromScan0(Int32 宽度,Int32 高度,Int32 步幅,Int32 格式,IntPtr scan0,IntPtr& 位图)

例外。

简单的例子:

 var pres = new Presentation(fn);
        for (var page = 0; page < pres.Slides.Count; page++)
        {
            ISlide slide = pres.Slides[page];
            
            slide.GetThumbnail());//.Save($\"{_currentDir}/output/{origfn}_{page + 1}.tiff\");
        }

我参考过:

<PackageReference Include=\"System.Drawing.Common\" Version=\"6.0.0\" />
<PackageReference Include=\"Aspose.Cells\" Version=\"22.8.0\" />
<PackageReference Include=\"Aspose.Email\" Version=\"22.7.0\" />
<PackageReference Include=\"Aspose.Imaging\" Version=\"22.8.0\" />
<PackageReference Include=\"Aspose.PDF\" Version=\"22.7.0\" />
<PackageReference Include=\"Aspose.Slides.NET\" Version=\"22.7.0\" />
<PackageReference Include=\"Aspose.Words\" Version=\"22.8.0\" />
<PackageReference Include=\"BitMiracle.LibTiff.NET\" Version=\"2.4.649\" />

    标签: image .net-core aspose aspose-slides


    【解决方案1】:

    不幸的是,Aspose.Slides 还不支持 .NET 6。 Aspose.Slides 22.11 仍计划支持 .NET 6。我为 Aspose 工作。

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2017-07-14
      • 2014-08-05
      • 2011-09-17
      相关资源
      最近更新 更多