Aspose PDF for C++ Debug环境有断言错误

您好,
我使用Aspose.PDF for C++库,在VS2017环境,使用MTd方式加载Aspose库,Debug环境下会出现断言错误,使用的代码如下:
int GetPDFPages(const std::wstring& strFilePath, const std::wstring& strPassword)
{
int nPages = 0;
try
{
System::String strDocument(strFilePath.c_str(), strFilePath.length());
System::String strDocumentPassword(strPassword.c_str(), strPassword.length());

    if (!System::IO::File::Exists(strDocument))
    {
        return Aspose_FileNotExist;
    }

    auto extractor =  System::MakeObject<Aspose::Pdf::Facades::PdfExtractor>();
    extractor->set_Password(strDocumentPassword);
    extractor->BindPdf(strDocument);
    nPages = extractor->get_EndPage();
}
catch (...)
{
    return Aspose_PasswordError;
}

return nPages;

}
该段代码目的是获取PDF总页数,断言错误截图如下:
断言错误.png (6.5 KB)

这个断言错误如何解决呢?

@Shen1

您能否确认您使用的是最新版本,即 C+ 21.7 的 Aspose.PDF?我们将进一步为您提供相应的帮助。

你好,再次确认了,我们使用的是Aspose.PDF.Cpp.21.7版本,
用你们的Aspose.PDF.Cpp.21.7\example\HelloWorld.sln,
编译Debug版本,将编译选项C/C++,Code Generation,Runtime Library改为Multi-thread Deubg(/MTd),运行就能再现出来。
请尽快回答。

@Shen1

我们能够在我们的环境中注意到类似的问题。我们注意到它只发生在 MTd 设置中。该项目在 MdD 设置下运行良好。

为了更正,我们在问题跟踪系统中将问题记录为 PDFCPP-1652。我们将调查其详细信息,并及时通知您其更正状态。请耐心等待,给我们一些时间。

我们对造成的不便很抱歉。