I want to remove a part of string from one character, that is:
Source string:
manchester united (with nice players)
Target string:
Using StringBuilder, you can replace the following way.
StringBuilder str = new StringBuilder("manchester united (with nice players)"); int startIdx = str.indexOf("("); int endIdx = str.indexOf(")"); str.replace(++startIdx, endIdx, "");