Converting excel to pdf cuts word with apostrophes when using rtl language

Hi,

Wrap text in pdf column cuts word with apostrophes when using rtl language.
I’ve added an excel file which i use aspose cells Save method:

var saveOptions = new Aspose.Cells.PdfSaveOptions();
saveOptions.AllColumnsInOnePagePerSheet = true;
public void Save(Stream stream, SaveOptions saveOptions);

both the excel file i’m reading from and the pdf i’m generating using the aspose.cells are attached:
Files.zip (78.5 KB)

the value i’m talking about is in the last row of the excel\pdf in the 3rd column from the right.
I’m using excel.cells version 16.12

Update: I’ve also tried using the new aspose.cells version 17.9 and it still happens!

Thanks

@TopSolutions,

Thanks for the template file and sample code.

Please try our latest version/fix: Aspose.Cells for .NET v17.11.7:

I have tested your scenario/case a bit using your template file and sample code, it works fine and I do not find your mentioned issue.

Let us know if you still find the issue.

Hi,

Thanks for the quick response…
unfortunately this case also happens with the new DLL.
Attached is a screenshot.

Have you tried it with my excel example?
Capture.JPG (69.1 KB)

@TopSolutions,

Thanks for the screenshot.

I have attached the output PDF file generated using your sample code segment. If you could open the PDF file into Adobe acrobat, you may see the words are not cut. Could you confirm it?

Please make sure that you are using v17.11.7 and also make sure that the underlying fonts (e.g “Tahoma”) used in the workbook is installed on your system. If you still find the issue with v17.11.7, kindly attach your output PDF file, we will check it soon.
out1.pdf (62.7 KB)

Hi,

I’ve looked at your PDF and this issue occures with it also, the diffrence is that in your case the line order has changed also.
As you can see the first line at your PDF starts with apostrophes - this is the continuation of the second line which cuts on those apostrophes. see the attached image where I’ve highlighted the entire word:
Capture.JPG (4.1 KB)

Regarding the bug where the line order is changed you have given us a workaround in the past so it doesnt matter right now, I will appriciate if you will have answers for me soon because right now it’s a show stopper at my product and my customers complain.

Thank you

By the way My generated PDF is attached on the first post on the Files.Zip file.

@TopSolutions,

Thanks for providing us further details and screenshot.

After further evaluation of your issue, I am able to observe the issue as you mentioned by converting your template file to PDF file format. I found by converting Excel to PDF, it cuts word with apostrophes when using RTL language. I confirmed, the difference i.e., the line order has changed. The first line in the PDF starts with apostrophes - this is the continuation of the second line which cuts on those apostrophes, here is the comparison screenshot:

I have logged a ticket with an id “CELLSNET-45808” for your issue. We will look into it soon.

Once we have an update on it, we will let you know here.

@TopSolutions,

We did evaluate your issue further.
After manually saving your file “Dashboard (23).xlsx” to PDF with MS Excel 2016, you can find the word is also cut in Page 6. (see the attached file: “Dashboard (23)_Excel2016.pdf”).
Could you share your output PDF saved by Microsoft Excel if there is some differences in your env.

After looking at text in Cell D8, we find the white space char is char 160 and not char 32. This may cause MS Excel take the text in Cell D8 as a word and not several words.
Dashboard (23)_Excel2016.pdf (156.3 KB)

Hi Amjad,

Thank you for the char suggestion i’ve replaced it in my excel generation to char 32…
After fixing this problem the PDF generated from regular save through Excel is OK but the excel generated through Aspose is still not OK…
Attached are the new excel file and the two PDF’S (one using Aspose and the other generated from regular excel save as PDF)
ExcelPDF.zip (195.4 KB)

Thank you

@TopSolutions,

Thanks for providing us template file and output PDFs.

I have logged your findings with template files against your issue “CELLSNET-45808” into our database. Our concerned developer from product team will evaluate your issue further.

Once we have any new information, we will share it with you.

@TopSolutions,

In your “Excel.xlsx” file, for laying out RTL language characters correctly, we separate RTL language characters (e.g. Hebrew) from the word רו"ח in cell L4, it is separated to three words רו,",ח so you can see the word being cut at line break. I am afraid, we cannot fix this issue now.

You might need to try to separate the text in Cell L4 to several lines by yourself in this case.

How can I seperate it by my self? this is just an example… my customers are generating reports and occacionally the last word in the row has apostrophes and the word cuts in the middle.
As you can see the excel file supports this words and somewhere inside your conversion to PDF this issue occures…
So this is a problem with Aspose component… how can I seperate the text into diffrent lines? I have no knowledge which word is at the end of the row… I cant drop line on each word that has apostrophes because it looks bad…
I need some workaround or an estimation to a date in which you will have a fix for this issue because my customers demend this from me.

Thank you

@TopSolutions,

I have logged your concerns against your issue “CELLSNET-45808” into our database. I have also asked the relevant developer from product team to evaluate it and provide some other way around (if possible) to cope with it.

Once we have any new information, we will share it with you.

@TopSolutions,

We have a good news for you. After spending a lot of time investigating your issue, we finally have found a possible way to fix it. We need about at least a week or so to fix it. So, kindly spare us 7-10 days or so, we will try to fix your issue in this time span and provide you the fix.

OK thank you for the update…

I will let my customers know about the time frame.

@TopSolutions,

Please try our latest version/fix: Aspose.Cells for .NET v17.12.4 (.NET 4.0)

Your issue should be fixed in it.

Let us know your feedback.

Hi,

It looks allright! thank you…
Now that the new DLL is implemented in my solution i get an unlicensed pdf report…
Does this fix means that I need a new license?

thank you

@TopSolutions,

Good to know that your issue is sorted out by the latest version/fix.

It looks like your license is expired (you may open your license into notepad and check subscription expiry date) to use the latest version/fix of the component. You may upgrade your subscription and get the new license, so you could use latest versions/fixes (for the next whole year) of the product without any restrictions/ limitations.

The issues you have found earlier (filed as CELLSNET-45808) have been fixed in this Aspose.Cells for .NET 18.1 update.

Please also check the following article: