I think it isn't symmetric.
I mean, take a pool of programmers that just know the standard format
characters ("C", "R", "X",...) - they can do ToString("C") and they know
what it means - then count how many of them know about NumberStyles and
IFromatProvider (probably less then 20%) - they can do Parse(s) but they
cannot do Parse(s, NumberStyles.AllowCurrency). -
This is what I mean for non symmetric.
If Decimal.ToString(format) cannot use "C" format of if
Decimal.Parse(string) implementation recognize a currency format, 100% of
them will be able to do ToString and then do Parse back. This is what I mean
for symmetric.
Don't you agree?
TIA (luKa)
http://nullabletypes.sourceforge.net/
On Tue, 2 Sep 2003 14:14:35 -0400, Akshay Arora <[EMAIL PROTECTED]> wrote:
>But it is symmetric. You did:
> string s = d.ToString( "C" ); // specify a "C" instead of
>default
>and then you did
> Decimal r = Decimal.Parse( s ); // leave default, don't specify
>Currency
===================================
This list is hosted by DevelopMentor� http://www.develop.com
NEW! ASP.NET courses you may be interested in:
2 Days of ASP.NET, 29 Sept 2003, in Redmond
http://www.develop.com/courses/2daspdotnet
Guerrilla ASP.NET, 13 Oct 2003, in Boston
http://www.develop.com/courses/gaspdotnet
View archives and manage your subscription(s) at http://discuss.develop.com