C# String Methods

You are Here:

C# String Methods

The following are the list of inbuilt string methods in C# programming.

Clone()Clones the string object, which returns another copy of same data.
Compare()Compares the characters of two strings (This method discriminates between lower case and upper case).
CompareOrdinal()Compares the characters of two strings and returns the difference in ASCII value.
CompareTo()Compares the characters of two strings (This method discriminates between lower case and upper case).
Concat()Appends the source string to the destination string.
Contains()Checks whether the substring occurs within a given string or not.
Copy()Creates a new instance of String with the same content as a specified string.
CopyTo()Copies a specified number of characters from the specified position in the string to a specified position in an array of characters.
EndsWith()Checks whether the specified string matches the end of the given string or not.
Equals()Checks whether the two specified String objects have the same value or not.
Format()Formats strings in a desired format by inserting objects and variables with specified padding into other strings.
GetEnumerator()Converts string object into char enumerator.
GetHashCode()Returns a hash code for this string.
GetType()Gets the type of the current instance.
GetTypeCode()Gets the underlying type code of the specified Type.


Hi Developers, we almost covered 90% of String functions and Interview Question on C# with examples for quick and easy learning.

We are working to cover every Single Concept in C#.

Please do google search for:

Join Our Channel

Join our telegram channel to get an instant update on depreciation and new features on HTML, CSS, JavaScript, jQuery, Node.js, PHP and Python.

This channel is primarily useful for Full Stack Web Developer.

Share this Page

Meet the Author