I think the problem is that the culture settings
for Norway don't default to the Euro symbol,
while the culture settings for other European
nations do default to the Euro.
See my example, online, at
http://asp.net.do/test/eurocurrency2.aspx
The Euro example at the top is for German culture ("de-DE"),
while the example at the bottom is for the Norway culture ("nn-NO")
Noptice that the DE culture displays the Euro,
which the Norway culture displays the Krone.
I added the localization to Dominican Pesos so you can see what
happens when you specify a culture which uses other currency symbols.
If you import the two classes :
<%@ Import Namespace="System.Globalization" %>
<%@ Import Namespace="System.Threading" %>
and run these 2 scripts in the Page_Load event in different pages,
you'll see that when the nn-NO script runs, the display is in KR,
but when the de-DE script runs, the display is in Euros.
<SCRIPT runat="server">
void Page_Load(){
String OutString = "";
CultureInfo NOCulture = new CultureInfo("nn-NO", false);
Thread.CurrentThread.CurrentCulture = NOCulture;
Decimal myCurrency = new Decimal( 123456 );
OutString = "Norway : " + myCurrency.ToString( "C", NumberFormatInfo.CurrentInfo );
Response.Write( OutString );
}
</SCRIPT>
<SCRIPT runat="server">
void Page_Load(){
String OutString = "";
CultureInfo DECulture = new CultureInfo("de-DE", false);
Thread.CurrentThread.CurrentCulture = DECulture;
Decimal myCurrency = new Decimal( 123456 );
OutString = "Germany : " + myCurrency.ToString( "C", NumberFormatInfo.CurrentInfo );
Response.Write( OutString );
}
</SCRIPT>
See the results of these 2 scripts at :
http://asp.net.do/test/eurocurrencyDE.aspx
and
http://asp.net.do/test/eurocurrencyNO.aspx
You could work around this by cloning the cultureinfo,
and substituting the Euro symbol for the kr symbol:
<SCRIPT runat="server">
void Page_Load(){
String OutString = "";
CultureInfo nnNOCulture = new CultureInfo("nn-NO", false);
Thread.CurrentThread.CurrentCulture = nnNOCulture;
NumberFormatInfo LocalFormat = (NumberFormatInfo)NumberFormatInfo.CurrentInfo.Clone();
LocalFormat.CurrencySymbol = "€"; // Replace Krone currency symbol with Euro symbol.
Decimal myCurrency = new Decimal( 123456 );
OutString = "Norway Culture with € symbol substituted : " + myCurrency.ToString("C", LocalFormat);
Response.Write( OutString );
}
</SCRIPT>
See *that* script demonstrated at
http://asp.net.do/test/eurocurrencyClone.aspx
There's not much more than I can do for you.
I hope you gets this to work.
Juan T. Llibre
ASP.NET MVP
===========