I want to do a simple poll page and I have a code that should work but it seems that the .cs file don't want to recognize the gridview\[code\]public partial class _Default : System.Web.UI.Page { int Count = 0; protected void Page_Load(object sender, EventArgs e) { } protected void btnVote_Click(object sender, EventArgs e) { if (radVote.SelectedItem != null) { InsertVotes(radVote.SelectedItem.ToString()); } else { lblStatus.ForeColor = Color.Red; lblStatus.Text = "Please select at least one option to vote for poll"; } } protected void InsertVotes(string theVote) { try { XmlDocument xmldoc = new XmlDocument(); xmldoc.Load(Server.MapPath("Votes.xml")); XmlElement parentelement = xmldoc.CreateElement("Vote"); XmlElement votechoice = xmldoc.CreateElement("Choice"); votechoice.InnerText = theVote; parentelement.AppendChild(votechoice); xmldoc.DocumentElement.AppendChild(parentelement); xmldoc.Save(Server.MapPath("Votes.xml")); lblStatus.ForeColor = Color.Green; lblStatus.Text = "Thank you for your vote."; } catch { lblStatus.Text = "Sorry, unable to process request. Please try again."; } }protected void readXML(){ int mCount = 0; int iCount = 0; int gCount = 0; XmlTextReader xmlreader = new XmlTextReader(Server.MapPath("Votes.xml")); DataSet ds = new DataSet(); ds.ReadXml(xmlreader); xmlreader.Close(); if (ds.Tables.Count > 0) { int dscount = ds.Tables[0].Rows.Count; for (int i = 0; i < dscount; i++) { if (ds.Tables[0].Rows[0].ToString() == "Mozilla") mCount++; else if (ds.Tables[0].Rows[0].ToString() == "Internet Explorer") iCount++; else if (ds.Tables[0].Rows[0].ToString() == "Google Chrome") gCount++; } double theTotal; theTotal = mCount + iCount + gCount; double mPercent; double oPercent; double gPercent; mPercent = (mCount / theTotal) * 100; oPercent = (iCount / theTotal) * 100; gPercent = (gCount / theTotal) * 100; double totalpercentage = mPercent + oPercent + gPercent; string[] votescount = { mCount.ToString(), iCount.ToString(), gCount.ToString() }; string[] array = { mPercent.ToString(), oPercent.ToString(), gPercent.ToString() }; DataTable dt = new DataTable(); dt.Columns.Add("OPTION_NAME"); dt.Columns.Add("VOTES"); dt.Columns.Add("PERCENTAGE"); int count = radVote.Items.Count; Count = count + 1; for (int i = 0; i < count; i++) { dt.Rows.Add(); dt.Rows["OPTION_NAME"] = radVote.Items.ToString(); dt.Rows["VOTES"] = votescount; dt.Rows["PERCENTAGE"] = array; } dt.Rows.Add("Total", theTotal, totalpercentage); gvResult.DataSource = dt; gvResult.DataBind(); } else { gvResult.DataSource = null; gvResult.DataBind(); }}protected void butResults_Click(object sender, EventArgs e){ readXML();}int cnt = 0;protected void gvResult_RowDataBound(object sender, GridViewRowEventArgs e){ if (e.Row.RowType == DataControlRowType.DataRow) cnt++; Label lblpercent = (Label)e.Row.FindControl("lblpercentage"); HtmlTable tblpercent = (HtmlTable)e.Row.FindControl("tblBar"); tblpercent.Width = lblpercent.Text+"%"; if (lblpercent.Text == "0") { tblpercent.Visible = false; } if (cnt == Count) { e.Row.CssClass = "TablePollResultFoot"; } foreach (TableCell tc in e.Row.Cells) { tc.Attributes["style"] = "border-color:#CCCCCC"; }}protected void btnResult_Click(object sender, EventArgs e){ readXML();}\[/code\]}the gvResult, radVote, lblStatus all have an error saying that the name doesn't exist in the current context. I have checked the names and everything seems to be fine but still I get this errors.In the html I have radiobuttonlist, a gridview, one button for voting and one button for showing the results