Home Forums General XMetaL Discussion XMetaL Developer: MCR-File with UTF-8 Encoding Reply To: XMetaL Developer: MCR-File with UTF-8 Encoding

Derek Read

Reply to: XMetaL Developer: MCR-File with UTF-8 Encoding

OK, so here's my fix:

1. Open your .JS file in XMetaL Developer's script editor (double click on it in the Project window).
2. In the Visual Studio main menu open File and select Save As.
3. In the Save As dialog save using the same filename and path (to overwrite the file) but change the encoding (using the little arrow on the Save button) to “Unicode – Codepage 1200”. This is Microsoft's equivalent of UTF-16.

Note that this assumes your file contains the correct characters (if not fix them before step 3).

Now when you build the project the MCR file will be encoded to UTF-16 (which you cannot change) and because this .JS input file is in the same encoding (also UTF-16) there won't be any character encoding issues.

Why building a project doesn't trigger a proper encoding change from UTF-8 (or whatever other encoding you might have the .JS file in) into UTF-16 for the MCR file I don't know, but I don't know that it is worth looking into if the fix is this simple.

Reply

Products
Downloads
Support