CSharp examples for System.Text.RegularExpressions:Match String
Is Only Characters by Regex
using System.Text.RegularExpressions; using System;/*from w w w.j ava 2s . com*/ public class Main{ public static bool IsOnlyCharacters(string character) { Regex regex = new Regex(@"^.[A-Za-z]+$"); return regex.IsMatch(character); } }