Home >>VB.Net Built-in Functions >VB.Net program to demonstrate the LCase() function
To convert the specified string to lowercase, the LCase() function is used.
Syntax :
LCase(Str)
Parameters :
Return Value :
Program :
The source code for demonstrating the function LCase() is given below. The program given is compiled and successfully executed.
Module Module1
Sub Main()
Dim str As String = "I LOVE INDIA"
Dim LCaseStr As String
LCaseStr = LCase(str)
Console.WriteLine("Lowercase string: {0}", LCaseStr)
End Sub
End Module
Explanation:
We created a Module1 module in the program above that contains the Main() method. Two variables str and LCaseStr were created in the Main() method, where variable str is initialized with 'I Love India' and variable LCaseStr is initialized with a blank string.
LCaseStr = LCase(str)
We used the LCase() function in the code above, which will return the lowercase string. Then, on the console screen, we printed the string.