Just type below two line in .cs page load
textbox1.Attributes.Remove("MaxLength"); textbox1.Attributes.Add("MaxLength", "30");
Hope it will help !