We're sorry Aspose doesn't work properply without JavaScript enabled.

Free Support Forum - aspose.com

Convert RTF to PDF/A-1b PDF/A Format using Java & Preserve Currency Values Symbols during Word to PDF Conversion

I have a problem converting an rtf file in pdf A.
The problem is that the generated pdf doesn’t contain a part of the rtf file.

This line of the rtf file
"<span style=“font-size:10.0pt;mso-bidi-font-size:12.0pt;
font-family:Verdana;mso-fareast-font-family:“Times New Roman”;mso-bidi-font-family:
“Times New Roman”;mso-ansi-language:IT;mso-fareast-language:IT;mso-bidi-language:
AR-SA;mso-no-proof:yes”>per i motivi esposti in premessa di approvare la spesa
di € <span style=“font-size:10.0pt;
mso-bidi-font-size:12.0pt;font-family:Verdana;mso-fareast-font-family:“Times New Roman”;
mso-bidi-font-family:“Times New Roman”;mso-ansi-language:IT;mso-fareast-language:
IT;mso-bidi-language:AR-SA”>5.500,00
<span style=“font-size:10.0pt;
mso-bidi-font-size:12.0pt;font-family:Verdana;mso-fareast-font-family:“Times New Roman”;
mso-bidi-font-family:“Times New Roman”;mso-ansi-language:IT;mso-fareast-language:
IT;mso-bidi-language:AR-SA;mso-no-proof:yes”> <span style=“font-size:10.0pt;mso-bidi-font-size:12.0pt;font-family:
Verdana;mso-fareast-font-family:“Times New Roman”;mso-bidi-font-family:“Times New Roman”;
mso-ansi-language:IT;mso-fareast-language:IT;mso-bidi-language:AR-SA”>(IVA
cpr.)
<span style=“font-size:10.0pt;mso-bidi-font-size:12.0pt;
font-family:Verdana;mso-fareast-font-family:“Times New Roman”;mso-bidi-font-family:
“Times New Roman”;mso-ansi-language:IT;mso-fareast-language:IT;mso-bidi-language:
AR-SA”> <!–[if gte mso 10]>

/* Style Definitions */ table.MsoNormalTable {mso-style-name:"Tabella normale"; mso-tstyle-rowband-size:0; mso-tstyle-colband-size:0; mso-style-noshow:yes; mso-style-parent:""; mso-padding-alt:0cm 5.4pt 0cm 5.4pt; mso-para-margin:0cm; mso-para-margin-bottom:.0001pt; mso-pagination:widow-orphan; font-size:10.0pt; font-family:"Times New Roman"; mso-ansi-language:#0400; mso-fareast-language:#0400; mso-bidi-language:#0400;}

<![endif]–>"
is converted in pdf in this way:

"per i motivi esposti in premessa di approvare la spesa di € ,00 (IVA cpr.) "

The number disappears !!

I attach the rtf file, the generated pdf file.
This is the code involved:

public static void testConvertpdf() throws Exception {
System.out.println(“begin”);

byte[] file = getFile(“test.rtf”);
PdfAgent instance = new PdfAgent();

Documento docIn = new Documento();
docIn.setContenuto(file);

Documento doc = instance.convertToPdf(docIn);

FileUtils.writeByteArrayToFile(new File(“output.pdf”), doc.getContenuto());

System.out.println(“end”);
}

PdfAgent:

public Documento convertToPdf(Documento file) throws Exception {
ByteArrayInputStream is = new ByteArrayInputStream(file.getContenuto());
com.aspose.words.Document doc = new com.aspose.words.Document(is);

PdfSaveOptions pdfOptions = new PdfSaveOptions();
pdfOptions.setCompliance(PdfCompliance.PDF_A_1_B);

ByteArrayOutputStream dstStream = new ByteArrayOutputStream();
doc.save(dstStream, pdfOptions);

Documento pdfFile = new Documento();
pdfFile.setContenuto(dstStream.toByteArray());

return pdfFile;
}


Thanks

It happens only if the text contains the character $ or <span style=“font-size:10.0pt;mso-bidi-font-size:12.0pt;
font-family:Verdana;mso-fareast-font-family:“Times New Roman”;mso-bidi-font-family:
“Times New Roman”;mso-ansi-language:IT;mso-fareast-language:IT;mso-bidi-language:
AR-SA;mso-no-proof:yes”>€ and there is something after written in bold.



I’m using aspose word 16.8.0

Hi Simone,

Thanks for your inquiry.

While using the latest version of Aspose.Words i.e. 16.10.0, we managed to reproduce this issue on our end. We have logged this issue in our bug tracking system. The ID of this issue is WORDSNET-14312. Your request has also been linked to the appropriate issue and you will be notified as soon as it is resolved. Sorry for the inconvenience.

Best regards,

Thanks, hope to receive a solution as soon as possible, for us this is a blocking problem…


Simone

Hi Simone,


Thanks for your inquiry. Unfortunately, this issue is not resolved yet. This issue is currently pending for analysis and is in the queue. We will inform you via this thread as soon as this issue is resolved. We apologize for any inconvenience.

Best regards,

Good morning,

any news about this issue ?
Thanks

Simone

We absolutely need this correction…

Hi Simone,


Thanks for your inquiry. Unfortunately, this issue is not resolved yet. This issue is currently pending for analysis and is in the queue. We will inform you via this thread as soon as this issue is resolved. We apologize for any inconvenience.

Best regards,

Hi, are you going to send this corretion with ther next version of the priduct ?
thanks

Simone

Hi Simone,


Yes, the fix will be integrated in next Aspose.Words 16.12.0 release.

Best regards,

Hi,

when will it be released ?

thanks

Hi Simone,


We will hopefully release 16.12.0 version of Aspose.Words during second week of December 2016.

Best regards,

The issues you have found earlier (filed as WORDSNET-14312) have been fixed in this Aspose.Words for .NET 16.12.0 update and this Aspose.Words for Java 16.12.0 update.


This message was posted using Notification2Forum from Downloads module by aspose.notifier.