Free Support Forum - aspose.com

Support for special characters like German umlauts (ä- ö- ü and etc.)

Hello There,

we're using Aspose.Tasks 1.6.1.0. When we create an MPX file (with tasks named e.g. "Zürich"), and open the MPX file in Project 2003, the name is corrupted to "Zürich". Must special characters be converted somehow?

Regards,

Andreas Tremel

Dear Andreas,

Thanks for considering Aspose.Tasks

Actually, MPX file can contain only ascii characters, so if these special characters are supported in ascii codes then Aspose.Tasks should work fine with them otherwise not.

Dear Shakeel,

thank you for the quick reply. Unfortunalely Ascii does not support any umlauts by standard. Can we escape those characters or use entities (like in HTML) so that project will recognise and display them correctly?

Best regards from Munich/Germany,

Andreas

Dear Shakeel,

I've tried to export a mpx file with Visio 2003. It also contains umlauts, they obviously aren't encoded (see the file attached). However, the umlauts in this mpx file are displayed correctly by Project (2003). It's a mystery to me? Is it a bug or can the encoding set in the file header?

Any help qould be appreciated! Thanks!

Cheers,

Andreas

Hello Andreas,

You mpx file created in Visio contains 850 codepage in the header.
Currently, Aspose.Tasks doesn’t allow to change codepages but
I think we can implement in a short time.

Dear Alexey,

Is the fix avalable yet?

Regards,
Andreas

Dear Andreas,

<?xml:namespace prefix = o ns = "urn:schemas-microsoft-com:office:office" />

No, it is not available yet and will take few more weeks. Thanks for your patience.

Dear Alexey,

this issue is really getting urgent. It's a vital thing for our customers to support umlauts, thats why we promised a solution. It's very anoying for users to correct the errors by hand.

We've reported this bug in november - I kindly ask you to provide a quick solution. Thank you very much.

Regards,
Andreas

Hello Andreas,

We will try to provide it before Monday.

Dear Aspose support,<?xml:namespace prefix = o ns = "urn:schemas-microsoft-com:office:office" />

I've installed the new version of Aspose Tasks, which should fix the issue with german umlauts.

Unfortunately I did not get it to work. Projects shows “äöpü” instead of “äöpü”.

I've tried the following:

file.MpxFileFormat.CodePage = "850";

and

FileStream fileStream = new FileStream(filePath, FileMode.OpenOrCreate);

file.Write(fileStream, Encoding.UTF8);

fileStream.Close();

(Where file is MPXFile)

What is wrong? Can you give me an example?

Regards,
Andreas

Dear Andreas,

<?xml:namespace prefix = o ns = "urn:schemas-microsoft-com:office:office" />

Can you provide some other mpx file, because this line gives exception of error reading file?

MPXFile file = new MPXFile(@"D:\downloads\mpx_umlauts.mpx");

How did you run your code and what was it exactly? Is the mpx_umlauts is a source mpx file or generated by Aspose.Tasks.?

Hi,

<?xml:namespace prefix = o ns = "urn:schemas-microsoft-com:office:office" />

Inside the attached zip package you will find a .mpx file which was created with our code.

Yes, its a file generated by Aspose..Tasks. In this case I use the following to generate the mpx-file:

MPXFile file = new MPXFile();

file.MpxFileFormat.CodePage = "850";

FileStream fileStream = new FileStream(filePath, FileMode.OpenOrCreate);

file.Write(fileStream, Encoding.UTF8);

fileStream.Close();

You will also find a screenshot of MS Project inside the zip package, where the mpx-file is opened.

Regards,

Andreas