[Mono-devel-list] Exception using CultureInfo
Gonzalo Paniagua Javier
gonzalo at ximian.com
Thu Oct 23 05:50:43 EDT 2003
El jue, 23-10-2003 a las 11:40, Jean-Marc ANDRE escribió:
> Hi,
>
> I've got a problem using CultureInfo.
> I've got an ArgumentException while using the constructor
> CultureInfo(string name).
> Don't know if it comes from my mono installation or if it is an internal
> bug.
> Here is what I get:
>
> Unhandled Exception: System.ArgumentException: An invalid argument was
> specified.
> in (unmanaged)
> /home/jim/monocvs/install/lib/libmono.so.0(mono_raise_exception+0x1b)
> [0x4007936f]
> in (unmanaged) /home/jim/monocvs/install/lib/libmono.so.0 [0x4009ee7d]
> in <0x0005a> System.Globalization.CultureInfo:Construct
> (int,string,bool)
> in <0x00098> System.Globalization.CultureInfo:.ctor (string,bool)
> in <0x00012> System.Globalization.CultureInfo:.ctor (string)
> in <0x0002d> .MainClass:Main ()
>
> while the following class:
>
> using System.Globalization;
>
> public class MainClass {
> public static void Main() {
> CultureInfo c = new CultureInfo("en-US");
> }
> }
After latest changes towards fully supporting globalization, mono relies
on ICU (http://oss.software.ibm.com/icu/). You have to install it and
compile mono to support that. If you don't, only InvariantCulture is
supported.
If you prefer, you can wait a little bit for the next mono release.
-Gonzalo
More information about the Mono-devel-list
mailing list