   [.net] ASP 2.0 calendar control
  Heya all,Having a little trouble with the calendar control in asp 2.0 using c#. I currently have it working reasonably as expected with the _SelectionChanged method, if a date is clicked on then the method is called, data accessed and all is well in the world.I am using the following code in the method to pull a dataset out based on the date clicked    protected void Calendar1_SelectionChanged(object sender, EventArgs e)    {   string sql = "select * from filedata where channel_id = " + DropDownList1.SelectedValue.ToString() + " and CONVERT(varchar(10), file_recordeddate, 103) LIKE '" + Calendar1.SelectedDate.ToShortDateString() + "' order by file_recordeddate desc, file_uploadeddate desc";   DataSet filedata = dataQuery(sql);   TableRow tempRow2 = new TableRow();   TableCell tempCell2 = new TableCell();   tempCell2.Text = "N.I.L.L. Program Guide for channel " + DropDownList1.SelectedItem.Text.ToString() + " dated " + Calendar1.SelectedDate.ToShortDateString();   tempRow2.Cells.Add(tempCell2);   Table2.Rows.Add(tempRow2);   foreach (DataRow dr in filedata.Tables["filedata"].Rows)   {  TableRow tempRow = new TableRow();  TableCell tempCell = new TableCell();  tempCell.Text = "<a href=\"./" + dr["file_url"].ToString() + "\">" + dr["file_title"].ToString() + "</a><hr />Recorded: " + dr["file_recordeddate"].ToString() + "<br />Duration: " + dr["file_duration"].ToString() + "<p />Description: " + dr["file_desc"].ToString() + "<p />";  tempRow.Cells.Add(tempCell);  Table1.Rows.Add(tempRow);   }    }If however I then click on the same date again, the table that had been filled is cleared and I just get a blank screen.My question is, how do I stop the table being cleared if a user clicks the same date again. My main concern is that since most of the users of the system will be english-as-second-language students this could be a common occurence and I don't want them to have to remember any more about how to use the system than to go to a specific url and then click the date and select the TV channel they want to see recorded content for.   
  What if you just wrap the contents of the method with a If(DropDownList1.SelectedValue != previous_value){    // method stuff here}That way it doesn't go thru and change the datatable if the same date is selected again.Sorry if this seems lame, but sounds like a simple work-around   ;  Thanks for the help Kabal, got it sorted though through talking to the microsoft dev evangelist here on the ready tour.Was down to the fact I was dynamically generating table rows and cells. I had to add an initial asp:tablerow and asp:tablecell into it and then set the text property in the selection changed event. If the selectionchanged event didn't fire after that the tablecell.text property didn't change and the text remained.   