InstantASP Community Forums
Home       Members    Calendar    Who's On
Welcome Guest ( Login | Register )
        



Problem with translation to dutch :... Expand / Collapse
Author
Message
Posted 09/05/2008 21:55:51
Forum Newbie

Forum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum Newbie

Group: Customers
Last Login: Today @ 12:02:23
Posts: 15, Visits: 164
Hi,

I have started to translate the software but ran into a problem with certain characters

I have a problem with certain characters in the globalization xml file.

here is one example from Resources.xml:
<item name="Button_EditCategories">Categoriën bewerken</item>

The problem here is the character  ë (but there are more characters that are causing this problem such as é, è )

It causes the following error:

Detailed error information follows:

Date and Time:         9-5-2008 22:44:28
Machine Name:          SERVICES
Process User:          NT AUTHORITY\NETWORK SERVICE
Remote User:          
Remote Address:        24.132.235.124
Remote Host:           24.132.235.124
URL:                   http://services.schmit.nl/KB20/Default.aspx

NET Runtime version:   2.0.50727.42
Application Domain:    /LM/W3SVC/1/Root/KB20-1-128548391496250000
Assembly Codebase:     C:/WINDOWS/assembly/GAC_MSIL/System.Xml/2.0.0.0__b77a5c561934e089/System.Xml.dll
Assembly Full Name:    System.Xml, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
Assembly Version:      2.0.0.0
Assembly Build Date:   16-6-2006 21:10:43

Exception Type:        System.Xml.XmlException
Exception Message:     Invalid character in the given encoding. Line 208, position 45.
Exception Source:      System.Xml
Exception Target Site: Throw

Post #13893
Posted 12/05/2008 18:05:36


IF.NET 4.2 Coming Soon

IF.NET 4.2 Coming SoonIF.NET 4.2 Coming SoonIF.NET 4.2 Coming SoonIF.NET 4.2 Coming SoonIF.NET 4.2 Coming SoonIF.NET 4.2 Coming SoonIF.NET 4.2 Coming SoonIF.NET 4.2 Coming Soon

Group: Administrators
Last Login: 14/07/2008 19:40:18
Posts: 1,929, Visits: 2,970
Hi Geert,

Hope your very well. Many thanks for your post. I think your our first user to create a language pack for InstantKB.NET

I believe i know what could be causing this problem. As our language files are XML based certain characters are not allowed and you need to provide the XML representation of that character. Also if you such certain characters with accents etc you will need to change the encoding type of the XML document. You can read more about the encoding types in the link below.

One common problem that catches many customers is the ampersand (& character. This character is not allowed in XML. For example the following string would throw an exception...

<<item name="KeyName">Preview & Print</item>

The correct way to represent this within XML would be...

<<item name="KeyName">Preview &amp; Print</item>

You can find a complete list of special characters within our forum documentation. As InstantKB.NET uses our localization code within the InstantASP.Common framework similar to the forum this information does apply to both. You can read more on this under the "XML Encoding & Special Characters" section at the link below...

http://docs.instantasp.co.uk/instantforum/creatingalanguagepack.html

For your problem i would suggest you first look at the encoding type of the XML document.

XML documents may contain foreign characters, like Norwegian æ ø å , or French ê è é. To ensure the XML parser understands these characters, you should save your XML resource files as Unicode. In XML, the character encoding is optional and can be given in the XML declaration in the first line of the document, like this:

<?xml version="1.0" encoding="iso-8859-1"?>

For most standard character sets we would suggest utf-8. The XML processor can recognize the following character set names:

UTF-8
UTF-16
ISO-10646-UCS-2
ISO-10646-UCS-4
ISO-8859-1 to -9
ISO-8859-11
TIS-620
ISO-2022-JP
Shift-JIS
EUC-JP

Examples of encoding declarations:

<?xml version="1.0" encoding="UTF-16"?>

<?xml version="1.0" encoding="EUC-JP"?> (for Japanese character)

<?xml version="1.0" encoding="iso-8859-11"?> (for Thai character )

If no encoding is given XML defaults to UTF-8. If you try to load an XML based resource file into Internet Explorer, you may one of the following error messages indicating encoding problems:

If you attach your resources.xml file here i'll happily take a quick look to see what could be causing the problem.


Kindest Regards,

Ryan Healey
Director / Developer

Explore our products...
http://demos.instantasp.co.uk/

Post #13905
Posted 12/05/2008 19:52:46
Forum Newbie

Forum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum Newbie

Group: Customers
Last Login: Today @ 12:02:23
Posts: 15, Visits: 164
Hi Ryan,

Thanks for the hint!

Simply saving the resources.xml with UTF-8 encoding in notepad did the trick!

If I run into more problems with translating I'll let you know.

Regards,

Geert

Post #13909
« Prev Topic | Next Topic »


Reading This Topic Expand / Collapse
Active Users: 0 (0 guests, 0 members, 0 anonymous members)
No members currently viewing this topic.
Forum Moderators: Ryan Healey, James Trott

Permissions Expand / Collapse

All times are GMT, Time now is 6:52pm

Powered by InstantForum.NET v4.1.4 © 2008
Execution: 0.063. 9 queries. Compression Disabled.
Home | Products | Purchase | Support | Company | Contact Us
Privacy Statement | © 1999-2007 InstantASP Limited. All Rights Reserved.