Change gridview to System.Web.UI.WebControls.GridView.