String format : String Format : String C# Examples


C# Examples » String » String Format »

 

String format









    
using  System;


class  MainClass
{
    public  static  void  Main(string[]  args)
    {
        string  formStr  =  null;
        formStr  =  string.Format("you  had  {0:C}  in  your  account?",  99989.987);
        Console.WriteLine(formStr);        
    }
}
    
   
  
   



Output

you had $99,989.99 in your account?


HTML code for linking to this page:

Follow Navioo On Twitter

C# Examples

 Navioo String
» String Format