LINQ Repoting Engine - My generated document has Font changes

Hello, Team I m using aspose .NET to generate document all the values needed as input i am providing correctly. But only for 1 document My font size and family changes. I haven’t encountered this issue before.

MainFileBeforeGeneraton.docx (17.1 KB)

GeneratedFile.docx (14.2 KB)

You can see the font size and font family of the generated document changed only in first line that too for some 4 words other things and all same could you please help me with this

No where I am changing the font and all…Its not happening for any other documents…

@Keerthana_K_R Could you please also attach your data source? We will check the scenario on our side and provide you more information.

Data.docx (94.5 KB)

I hope this should be fine…

@Keerthana_K_R Could you please provide the data source in the form you pass it into the LINQ reporting engine, i.e. JSON or XML?

engine.BuildReport(doc, Data, "NameusedinAsposeDocumetent");

I am building in this way…
Here I will be gving data as a object

DataSourceDoc.docx (13.3 KB)

This will have many datas please ignore others

At last you can see those data’s used in Main document

DataSourceDoc.docx (11.9 KB)

Has only required datas you can check this

@Keerthana_K_R
We have opened the following new ticket(s) in our internal issue tracking system and will deliver their fixes according to the terms mentioned in Free Support Policies.

Issue ID(s): WORDSNET-25907

You can obtain Paid Support Services if you need support on a priority basis, along with the direct access to our Paid Support management team.

How long will it take may I know…?

@Keerthana_K_R Unfortunately, at the moment it is difficult to say what causes the problem and how long it take to fix the problem. At the moment issue is in the queue for analysis. Once analysis is done, we will be able to provide you more information.

@Keerthana_K_R

While analyzing WORDSNET-25907, it appeared that the issue is caused by the template document. Here are the details:

The paragraph containing “Three (3)” has the paragraph style. The style has the Times New Roman 12pt font applied. All runs of the paragraph have direct formatting with the Arial 10pt font set.

But the paragraph containing “For each analyte, three (3)” has the Normal style. The style has the Arial 10pt font applied. In turn, runs of the paragraph have no direct formatting for its ASCII font defined.

So that, when tag ranges are removed, “For each analyte, three (3)” runs are moved to the paragraph containing “Three (3)” and since the runs do not have direct formatting applied, they inherit it from the paragraph style, thus the font becomes Times New Roman.

To resolve the issue, you may apply the Normal style to the paragraph containing “Three (3)”.

Thank you for that’

1 Like

The issues you have found earlier (filed as WORDSNET-25907) have been fixed in this Aspose.Words for .NET 23.11 update also available on NuGet.