how to search for single quote char in c# code example Example: c# handle single quote inside string s = s.Replace("'", "\\'")