Spire.Doc is a professional Word .NET library specifically designed for developers to create, read, write, convert and print Word document files. Get free and professional technical support for Spire.Doc for .NET, Java, Android, C++, Python.

Thu Dec 08, 2022 6:38 pm

Hello,
When embedding an ole object of file with name in hebrew so the name as result is in wrong encoding.
How can I fix that please?

one.cthulhu.dev
 
Posts: 6
Joined: Tue Nov 08, 2022 2:45 pm

Fri Dec 09, 2022 9:22 am

Hello,

Thanks for your inquiry.
According to your message, I can’t exactly investigate it. To help us reproduce your issue and work out a solution for you, please offer the following message, thanks for your assistance in advance.
1) Your input document (if any), you can attach here or send it to us via email ([email protected]).
2) Your full test code that can reproduce your issue.
3) Application type, such as Console App, .NET Framework 4.8.
4) Your test environment, such as OS info (E.g. Windows 7, 64-bit) and region setting (E.g. China, Chinese).

Sincerely
Abel
E-iceblue support team
User avatar

Abel.He
 
Posts: 1010
Joined: Tue Mar 08, 2022 2:02 am

Sat Dec 10, 2022 12:24 pm

Hello,
Thank you for your answer.

1. Tested with many documents, even empty ones. It may be pdf or docx - same result.
2. Test code:
Code: Select all
Spire.License.LicenseProvider
    .SetLicenseFileFullPath("license.elic.xml");

var doc = new Document();
var section = doc.AddSection();
var para = section.AddParagraph();
var pic = new DocPicture(doc);
pic.LoadImage("file-icon.jpg");
para.AppendOleObject("קובץ לדוגמה.pdf", pic, OleObjectType.Package);
doc.SaveToFile("Result.docx");

as a result the embeded file name is
קובץ לדוגמה.pdf

Tested with OleLinkType.Embed to.
3. Application type is Console App dotnet core net6.0, net7.0
4. Tested on several environments: macOS Ventura, Windows 11 Pro (m1 parallels), Windows 11 Pro (Intel) and Windows server 2019
All the environments are x64, region - Israel

Thank you very much!

P.S. In addition the one more issue we have:
After clicking on the embedded item icon switches to original icon by file type and the filename shown without any word-wrapping.
And here are two options what happens:
1. The width of the icon was not set - so if the file name is too long it fills all document width and may scrolls out to.
2. The width of the icon was set - so it fills all available width of replaced icon and if the file name is too long the height of the object that appears (file-type-icon + file-name) is too small.

one.cthulhu.dev
 
Posts: 6
Joined: Tue Nov 08, 2022 2:45 pm

Mon Dec 12, 2022 4:06 am

Hello,

Thanks for your feedback.
I'll do further investigation, I'll give you feedback asap.

Sincerely
Abel
E-iceblue support team
User avatar

Abel.He
 
Posts: 1010
Joined: Tue Mar 08, 2022 2:02 am

Tue Dec 13, 2022 8:38 am

Hello,


Thanks for your patiently waiting.
After investigation, I have reproduced the issue of the file name garble, and I logged it into our bug tracking system with the ticket number SPIREDOC-8891. Our development team will investigate and fix it. Once it is resolved, I will inform you in time. Sorry for the inconvenience caused.
In addition, for the new issue you mentioned, these situations happen not under the control of Spire.doc but under the control of MS Word.

Sincerely
Abel
E-iceblue support team
User avatar

Abel.He
 
Posts: 1010
Joined: Tue Mar 08, 2022 2:02 am

Sat Dec 17, 2022 7:01 pm

Hello,
Thanx a lot for the answer.
Actually we got the second issue when tried to fix the main one.
The goal was to see as a result the icon of the file with the name (with ellipsis in case of the name is long).
Unfortunately we did not find an option to show the file name.
So we generate an image with the icon and the name.
But you know, when we saw what happens on click it negatively surprised us.

Anyway, we are looking forward to your update.
Thank you very much.

one.cthulhu.dev
 
Posts: 6
Joined: Tue Nov 08, 2022 2:45 pm

Mon Dec 19, 2022 7:53 am

Hello,

Thanks for your response.
We are sorry for the inconvenience caused by us. We will try our best to fix SPIREDOC-8891 ASAP and inform you once it is solved.

Sincerely,
Amy
E-iceblue support team.
User avatar

amy.zhao
 
Posts: 3011
Joined: Wed Jun 27, 2012 8:50 am

Fri Dec 30, 2022 10:47 am

Hello,

Greeting from E-iceblue.
For the issue with the number SPIREDOC-8891, I have some information to tell you:

We just released Spire.Doc 10.12.4 which fixes this issue to some extent, relative to Spire.Doc 10.11.9, the latest version fixes the pdf document name when you double-click the pdf icon to open it, but there are still issues with the name of the icon displayed in the word document. As shown in the screenshot below. However, according to the feedback from our development team, the icon generated by MS Word after double-clicking the Pdf icon generated by Spire.Doc is beyond the control of Spire.Doc, therefore, we can’t fix the issue of incorrectly displaying the pdf file name in pdf icon. Sorry for the inconvenience caused.


Sincerely
Abel
E-iceblue support team
User avatar

Abel.He
 
Posts: 1010
Joined: Tue Mar 08, 2022 2:02 am

Return to Spire.Doc