Information on release notes v18.5

Hello,

On Apose.PDF when switching between version 18.1 and version 20.6, you get the following error:

‘Document’ does not contain a definition for ‘PdfaFormat’ and no extension method ‘PdfaFormat’ accepting a first argument of type ‘Document’ could be found

This modification of the API dates from V18.5, yet nothing is reported on the release notes of this version. Could we have some information about this change.

Thank you in advance

@CSCT

Would you kindly share the code snippet (patch) which was working in 18.1v and now generating issue in 20.6v. We will share our feedback with you accordingly.

Here is the code snippet that worked in v18.1 and now generates a problem in v20.6:

public String GetPdfaFormat(MemoryStream file)
{
logger.Debug(“Begin GetPdfaFormat”);
String format = String.Empty;
try
{
Document inputPdfFile = new Document(file);
//Take format of file
format = inputPdfFile.PdfaFormat.ToString();
logger.Info("format of file ==> " + format);
if (String.IsNullOrEmpty(format))
{
//Is a PDF file
format = String.Empty;
}
logger.Debug(“End GetPdfaFormat”);
return format;
}
catch (Exception ex)
{
logger.Error("GetPdfaFormat with error : " + ex.Message);
return format;
}

}

This is the line “format = inputPdfFile.PdfaFormat.ToString();”

And also the line “pdfFormat = PdfFile.PdfaFormat.ToString();”, “PdfFile” is of the type “Document” :

try
{
pdfFormat = PdfFile.PdfaFormat.ToString();
}
catch
{
pdfFormat = String.Empty;
logger.Warn(“Error during format of PdfFile. Is an Pdf or another problem.”);
}

Thank you in advance

@CSCT

The mentioned property has been replaced with Document.PdfFormat. You may please use it in your code snippet. In case of any further assistance, please feel free to let us know.