Health & Medical sports & Exercise

Visual C Sharp String Functions

String.Substring()

  • The "Substring()" method takes either one or two integer arguments and returns a substring from a larger existing string. Strings in C# are represented as 0 index collections of characters. The first argument represents the starting index of the substring. The second argument represents the ending index. If the programmer provides only one argument, the method will return a substring from the argument's index through the end of the string. The following example details the Substring method.

    string ex = "This is a String";

    string sub = ex.Substring(10); //"String"

    string sub2 = ex.Substring(0, 6); //"This is"

Related posts "Health & Medical : sports & Exercise"

The Old Hand' s Comprehensive Reference For Tourists Wishing To Voyage For The Caribbean Voyage

sports

The Language Of Golf

sports

Finding The Right Dance Studio For Your Child

sports

Military Team Logo And Gear

sports

The Health Benefits of Aerobics

sports

Softball Hitting Tips: Aluminum Vs. Wooden Bats

sports

How to Determine a Bowling Score

sports

Developing College Sports Preparation Drills

sports

Nine Types Of Mountain Biking

sports

Leave a Comment