C# | Int64.ToString Method | Set - 1 Last Updated : 11 Jul, 2025 Summarize Comments Improve Suggest changes Share Like Article Like Report Int64.ToString Method is used to convert the numeric value of the current instance to its equivalent string representation. There are 4 methods in the overload list of this method as follows: ToString(IFormatProvider) MethodToString(String, IFormatProvider) MethodToString( ) MethodToString(String) Method Here we will discuss the first two methods. ToString(IFormatProvider) Method This method is used to convert the numeric value of this instance to its equivalent string representation using the specified culture-specific format information.Syntax: public string ToString (IFormatProvider provider); Parameters: This method takes an object of type IFormatProvider which supplies culture-specific formatting information.Return Value: This method returns the string representation of the value of the current object in the format specified by the provider parameter.Example: csharp // C# program to demonstrate // Int64.ToString(IFormatProvider) // Method using System; using System.Globalization; class GFG { // Main Method public static void Main() { // declaring and initializing // Int64 value long val = Int64.MaxValue; // creating and initializing // the object of CultureInfo CultureInfo provider = new CultureInfo("en-us"); // using the method string str = val.ToString(provider); // Display the value Console.WriteLine("The Value is {0} and provider is {1}", str, provider.Name); } } Output: The Value is 9223372036854775807 and provider is en-US Int64.ToString(String, IFormatProvider) Method This method is used to convert the numeric value of this instance to its equivalent string representation using the specified format and culture-specific formatting information. Syntax: public string ToString (string format, IFormatProvider provider);Parameters: format: It is a numeric format string. provider: It is an object which supplies culture-specific formatting information.Return Value: This method returns the string representation of the value of the current instance as specified by format and provider. Example: csharp // C# program to demonstrate the // Int64.ToString(String, IFormatProvider) // Method using System; using System.Globalization; class GFG { // Main Method public static void Main() { // declaring and initializing // Int64 value long val = 4627836321; // creating and initializing // the object of CultureInfo CultureInfo provider = new CultureInfo("fr-FR"); // declaring and initializing format string format = "D5"; // using the method string str = val.ToString(format, provider); // Displaying the details Console.WriteLine("The value is {0}",str); Console.WriteLine("The Format is {0}",format); Console.WriteLine("The Provider is {0}", provider.Name); } } Output: The value is 4627836321 The Format is D5 The Provider is fr-FR Reference: https://learn.microsoft.com/en-us/dotnet/api/system.Int64.tostring?view=netframework-4.7.2 Comment More infoAdvertise with us Next Article C# | Int64.ToString Method | Set - 2 K Kirti_Mangal Follow Improve Article Tags : C# CSharp-method CSharp-Int64-Struct Similar Reads C# | Int64.ToString Method | Set - 2 Int64.ToString Method is used to convert the numeric value of the current instance to its equivalent string representation. There are 4 methods in the overload list of this method as follows: ToString(IFormatProvider) Method ToString(String, IFormatProvider) Method ToString() Method ToString(String) 2 min read C# | Int64.ToString Method | Set - 2 Int64.ToString Method is used to convert the numeric value of the current instance to its equivalent string representation. There are 4 methods in the overload list of this method as follows: ToString(IFormatProvider) Method ToString(String, IFormatProvider) Method ToString() Method ToString(String) 2 min read C# | Int16.ToString Method | Set - 1 Int16.ToString Method is used to convert the numeric value of the current instance to its equivalent string representation. There are 4 methods in the overload list of this method as follows: ToString(IFormatProvider) Method ToString(String, IFormatProvider) Method ToString() Method ToString(String) 2 min read C# | Int16.ToString Method | Set - 1 Int16.ToString Method is used to convert the numeric value of the current instance to its equivalent string representation. There are 4 methods in the overload list of this method as follows: ToString(IFormatProvider) Method ToString(String, IFormatProvider) Method ToString() Method ToString(String) 2 min read C# | Int16.ToString Method | Set - 2 Int16.ToString Method is used to convert the numeric value of the current instance to its equivalent string representation. There are 4 methods in the overload list of this method as follows: ToString(IFormatProvider) Method ToString(String, IFormatProvider) Method ToString() Method ToString(String) 2 min read C# | Int16.ToString Method | Set - 2 Int16.ToString Method is used to convert the numeric value of the current instance to its equivalent string representation. There are 4 methods in the overload list of this method as follows: ToString(IFormatProvider) Method ToString(String, IFormatProvider) Method ToString() Method ToString(String) 2 min read Like