Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR CSHARP

c# swap name in string

//Example for name formatting "Wonderland, Alcie" => "Alice Wonderland"
string name = "Wonderland, Alcie";
string[] newName = name.Split(", ");
(newName[0], newName[1])=(newName[1], newName[0]);
name = String.Concat(newName[0]," ", newName[1]);
 
PREVIOUS NEXT
Tagged: #swap #string
ADD COMMENT
Topic
Name
1+8 =