- Home
- Forum
- ASP.NET MVC - EJ 2
- Getting blank Hindi text in pdf file when converting pptx to pdf
Getting blank Hindi text in pdf file when converting pptx to pdf
Hi
Attachment: PPTX_6824a254.zip
We are trying to convert pptx to pdf using the presentationtopdfconverter in Azure App Service.
The file is converted successfully, but Hindi text is not rendered in the pdf.
Tried to use font substitution, and found that no missing font is reported, perhaps because we are embedding fonts in the presentation.
Input PPTX and the output PDF files are attached.
Pl advise asap.
Thanks
Attachment: PPTX_6824a254.zip
SIGN IN To post a reply.
10 Replies
1 reply marked as answer
MR
Manikandan Ravichandran
Syncfusion Team
July 2, 2020 08:27 AM UTC
Hi Abhishek,
Thank you for contacting Syncfusion support
We can reproduce the reported issue with “Hindi text preservation issue while converting PPTX document to PDF in Azure environment” in our end, and we suspect it to be a defect. We will validate this issue and update you with more details on 6th July 2020.
Please let us know if you have any other questions.
Regards,
Manikandan Ravichandran
Thank you for contacting Syncfusion support
We can reproduce the reported issue with “Hindi text preservation issue while converting PPTX document to PDF in Azure environment” in our end, and we suspect it to be a defect. We will validate this issue and update you with more details on 6th July 2020.
Please let us know if you have any other questions.
Regards,
Manikandan Ravichandran
Hi Abhishek,
Thank you for contacting Syncfusion support
We can reproduce the reported issue with “Hindi text preservation issue while converting PPTX document to PDF in Azure environment” in our end, and we suspect it to be a defect. We will validate this issue and update you with more details on 6th July 2020.
Please let us know if you have any other questions.
Regards,
Manikandan Ravichandran
Thanks for your confirmation.
Kindly provide a solution/workaround asap because this is a production LMS app and issue reported by our end users.
Thanks
MR
Manikandan Ravichandran
Syncfusion Team
July 6, 2020 03:39 PM UTC
Hi Abhishek,
Thank you for your patience.
From our further investigation, we found this text missing issue occurs due to using a default font “Arial” font to draw the “Hindi” (complex script) text, instead of a “Mangal” font. Also, we found this requirement as “Support to detect a font name from theme for complex script characters while PPTX to PDF conversion” feature in our end. However, we have planned to include this feature in our 2020 Volume 3 Main release which is estimated to be available on end of September 2020 tentatively.
The status of the feature can be tracked through below feedback link.
https://www.syncfusion.com/feedback/15802/support-to-detect-a-font-name-from-theme-for-complex-script-characters-while-pptx
Please let us know if you have any other questions.
Regards,
Manikandan Ravichandran
Thank you for your patience.
From our further investigation, we found this text missing issue occurs due to using a default font “Arial” font to draw the “Hindi” (complex script) text, instead of a “Mangal” font. Also, we found this requirement as “Support to detect a font name from theme for complex script characters while PPTX to PDF conversion” feature in our end. However, we have planned to include this feature in our 2020 Volume 3 Main release which is estimated to be available on end of September 2020 tentatively.
The status of the feature can be tracked through below feedback link.
https://www.syncfusion.com/feedback/15802/support-to-detect-a-font-name-from-theme-for-complex-script-characters-while-pptx
Please let us know if you have any other questions.
Regards,
Manikandan Ravichandran
AS
Abhishek Singhal
July 12, 2020 11:30 AM UTC
Thanks for getting back.
Is there any instruction we can give to user regarding their pptx file so that it can get converted correctly ?
Kindly advise.
MR
Manikandan Ravichandran
Syncfusion Team
July 13, 2020 11:14 AM UTC
Hi Abhishek,
Thank you for your update.
To resolve the reported Hindi text missing issue, we suggest you to mention the font used for the Hindi text to the corresponding text in the presentation document by iterating the each shapes and slides as mentioned below.
Thank you for your update.
To resolve the reported Hindi text missing issue, we suggest you to mention the font used for the Hindi text to the corresponding text in the presentation document by iterating the each shapes and slides as mentioned below.
|
//Load the PowerPoint document IPresentation pptxDoc = Presentation.Open(@"महिला सशक्तिकरण (नारी शक्ति).pptx"); ApplyFont(pptxDoc); //Initialize the conversion settings PresentationToPdfConverterSettings pdfConverterSettings = new PresentationToPdfConverterSettings(); //Enable the portable rendering. pdfConverterSettings.EnablePortableRendering = true; //Convert the PowerPoint document to PDF PdfDocument pdfDoc = PresentationToPdfConverter.Convert(pptxDoc, pdfConverterSettings); //Save the converted PDF file. pdfDoc.Save("Sample.pdf"); //Close the presentation instance pptxDoc.Close(); //Close the PDF instance pdfDoc.Close(); Process.Start("Sample.pdf"); |
|
private void ApplyFont(IPresentation pptxDoc) { foreach (ISlide slide in pptxDoc.Slides) { foreach (IShape shape in slide.Shapes) { foreach (IParagraph paragraph in shape.TextBody.Paragraphs) { foreach (ITextPart textPart in paragraph.TextParts) { textPart.Font.FontName = "Mangal"; } } } } } |
As mentioned earlier, we will planned to implement and include this feature in our 2020 volume 3 main release which will be available on end of September 2020.
Please let us know if you have any other questions.
Regards,
Manikandan Ravichandran
AS
Abhishek Singhal
July 13, 2020 01:18 PM UTC
Two issues
Attachment: outxxfile_b0fd8345.zip
- How to find which font to replace. Using the code provided, all fonts would get replaced - even in a normal English pptx. We don't know what file is uploaded by which user and need to handle all types of files.
- Using the code provided, we got the pdf as attached. There are spelling changes and > character is introduced at many places. Output is not in "ready" shape.
Pl advise asap.
Attachment: outxxfile_b0fd8345.zip
MR
Manikandan Ravichandran
Syncfusion Team
July 14, 2020 12:33 PM UTC
Hi Abhishek,
Thank you for your update.
We have suggested a workaround solution to resolve the particular document alone. Once the mentioned feature implemented the reported issue will resolve in your end. As mentioned earlier, we have planned to implement and include this feature in our 2020 volume 3 main release which will be available on end of September 2020 tentatively.
Reg - There are spelling changes and > character is introduced at many places. Output is not in "ready" shape.
We have ensured the document given document with the provide code example, and its working fine in our end. We have attached the generated output document in Azure environment and it can be downloaded from the below link.
https://www.syncfusion.com/downloads/support/forum/155681/ze/Output-469805964
We have published application I Azure environment, kindly ensure the document using this link.
https://mvcsample20200702125126.azurewebsites.net/
Please let us know if you have any other questions.
Regards,
Manikandan Ravichandran
Thank you for your update.
We have suggested a workaround solution to resolve the particular document alone. Once the mentioned feature implemented the reported issue will resolve in your end. As mentioned earlier, we have planned to implement and include this feature in our 2020 volume 3 main release which will be available on end of September 2020 tentatively.
Reg - There are spelling changes and > character is introduced at many places. Output is not in "ready" shape.
We have ensured the document given document with the provide code example, and its working fine in our end. We have attached the generated output document in Azure environment and it can be downloaded from the below link.
https://www.syncfusion.com/downloads/support/forum/155681/ze/Output-469805964
We have published application I Azure environment, kindly ensure the document using this link.
https://mvcsample20200702125126.azurewebsites.net/
Please let us know if you have any other questions.
Regards,
Manikandan Ravichandran
AS
Abhishek Singhal
July 14, 2020 12:49 PM UTC
Hello
Is it possible to provide a workaround for detecting type of document and applying the font substitution in that case only ?
Sep 2020 is ~3 months away and we need to provide our users with some mechanism to convert such pptx to pdf.
Thanks
MR
Manikandan Ravichandran
Syncfusion Team
July 15, 2020 12:27 PM UTC
Hi Abhishek,
Thank you for your update.
As mentioned earlier, we don’t have any workaround for resolving the issue until the mentioned feature implemented. We have planned to implement and include this feature in our 2020 volume 3 main release which will be available on end of September 2020 tentatively.
Please let us know if you need any further assistances in this.
Regards,
Manikandan Ravichandran
Thank you for your update.
As mentioned earlier, we don’t have any workaround for resolving the issue until the mentioned feature implemented. We have planned to implement and include this feature in our 2020 volume 3 main release which will be available on end of September 2020 tentatively.
Please let us know if you need any further assistances in this.
Regards,
Manikandan Ravichandran
MR
Manikandan Ravichandran
Syncfusion Team
October 6, 2020 07:00 AM UTC
Hi Abhishek,
We are glad to announce that our Essential Studio 2020 Volume 3 release v18.3.0.35 is rolled out and is available for download under the following link.
https://www.syncfusion.com/forums/158306/essential-studio-2020-volume-3-release-v18-3-0-35-is-available-for-download
We thank you for your support and appreciate your patience in waiting for this release. Please get in touch with us if you would require any further assistance.
Regards,
Manikandan Ravichandran
We are glad to announce that our Essential Studio 2020 Volume 3 release v18.3.0.35 is rolled out and is available for download under the following link.
https://www.syncfusion.com/forums/158306/essential-studio-2020-volume-3-release-v18-3-0-35-is-available-for-download
We thank you for your support and appreciate your patience in waiting for this release. Please get in touch with us if you would require any further assistance.
Regards,
Manikandan Ravichandran
Marked as answer
SIGN IN To post a reply.
- 10 Replies
- 2 Participants
- Marked answer
-
AS Abhishek Singhal
- Jul 1, 2020 06:09 PM UTC
- Oct 6, 2020 07:00 AM UTC