I know I can append to a string but I want to be able to add a specific character after every 5 characters within the string
from this string alpha = abcdefghijklmno
Inserting Space in emailId field after every 8 characters
public string BreakEmailId(string emailId) { string returnVal = string.Empty; if (emailId.Length > 8) { for (int i = 0; i < emailId.Length; i += 8) { returnVal += emailId.Substring(i, 8) + " "; } } return returnVal; }