DataRow dr = dataset.Tables[0].Rows[i]; 
int k = (int)dr[0];上面这段代码中,如果dr[0]的字段的类型为smallint,就会出错,同样是数值类型,有什么好方法解决该问题?