Look at the code directly:
public static string Converttochinesemoney (double)
{
if (Money < 0)
throw new ArgumentOutOfRangeException ("parameter money cannot be negative!") ");
string s = Money. ToString ("#L #e#d#c#k#e#d#c#j#e#d#c#i#e#d#c#h#e#d#c#g#e#d#c#f#e#d#c#.0b0a");
s = Regex.Replace (S, @ "(? <=-|^) [^1-9]*) | ( (?' Z ' 0] [0a-e]* (? =[1-9]) | (?) -Z ' (? =[f-l\.]| $))))| ((?' B ' [f-l]) (? ') Z ' 0] [0a-l]* (? =[1-9]) | (?) -Z ' (? =[\.]| $))) ("${b}${z}"));
Return Regex.Replace (S, ".", Delegate (Match m) {return "negative Yuan 0 a third Woolu qi ba Shing empty empty points to collect the million trillion Beijing gai 秭 rang" [m.value[0]-'-']. ToString (); });
}
Call this method:
Random r = new Random ();
for (int i = 0; i < i++)
{
Double m = r.next ()/100.0;
Response.Write (M + "----" + Converttochinesemoney (m) + "<br/>");
}
To test, the results are as follows:
5970370.36----Wu Ying, QI, 6521548.6, seven, Nine, Ten, ten, three,----, Wu Bai Wu to pick up the Ba Yuan Lu Kok 12179380.35----A thousand thousands of thousands of thousands of thousands of thousands of thousands of
BA to collect the three-
point Wood 15742735.47----Wu bai qi qi bai qi Wu Yuan jiao qi 9236554.09----Nine to pick up three Lu Ying Wu Wu to pick up Yuan points 9706980.49----nine million Qi Lu Ying
Bai ba pick Yuan restaurant corner nine points 11873034.16----One thousand thousand thousands of BA seven thousands of 0 to pick up a corner of the 21141596.22----, one by one, one by one, to pick up the Lu Yuan of the
seven-point Wu Ying 17040243.44
---- Seven hundred 0 establishments to pick up three yuan in the
5358585.54----Wu Bai Ba Wu Wu ba pick up Wu Yuan Wu Kok restaurant points