find and solve || findandsolve.com
Please wait.....

C# String ToLowerInvariant()

In the C# String.ToLowerInvariant() method is used to return a copy of this String object converted to lowercase using the casing rules of the invariant culture.

Syntax

public string ToLowerInvariant() 

Parameter

It does not take any parameter.

Return

The return type of this method is System.String. This method returns a string which is a lowercase equivalent of the current string.


C# String ToLowerInvariant() Method Example

using System;
public class Program
{
 public static void Main()
 {
    string str = "Hello Find And Solve";
      string str1 = str.ToLowerInvariant();
      Console.WriteLine(str1);
 }
}

Output

hello find and solve


Other Example

using System;
public class Program
{
 public static void Main()
 {
        // calling function
        Convert("FindandSolve");
        Convert("findandsolve");
        Convert("FINDANDSOLVE");
    }
    public static void Convert(String param)     {
        // Display strings
        Console.WriteLine("String 1: {0}", param);
        // Convert sting into Lowercase
        // using ToLowerInvariant() method
        param = param.ToLowerInvariant();
        // Display the Lowercase strings
        Console.WriteLine("String 2: {0}", param);
  }
}

Output

String 1: FindandSolve

String 2: findandsolve

String 1: findandsolve

String 2: findandsolve

String 1: FINDANDSOLVE

String 2: findandsolve