Answers for "text.remove unity"

C#
9

unity delete specific text in a string

public string strOne = "Hello World";
public string strTwo = " World";

public void DeleteStrTwoFromStrOne()
{
	strOne = strOne.Replace(strTwo, ""); //strOne = "Hello" now
}
Posted by: Guest on April-04-2020
-1

unity add text to text field without deleting the old one

myTextField.text = myTextField.text + " whatever extra you want to add"
Posted by: Guest on February-16-2021

C# Answers by Framework

Browse Popular Code Answers by Language