异常总是在以下语句中引发..:
protected void DataList2_SelectedIndexChanged(object sender, EventArgs e)
{
x= should get the primary key of the item selected from a datalist
Server.Transfer("AnswerQuestion.aspx?x=" + int.Parse(DataList2.DataKeyField) + "&question=" +"bla bla") + "&time=" + DateTime.Now);
}
它在这里抛出异常..:(即使我将它分开 int threadID = int.Parse(DataList1.DataKeyField.ToString()); 为什么?