public string[] GetNews(int id)
{
OleDbConnection con=CreateCon();
OleDbDataReader oddr;
try
{
con.Open();
OleDbCommand cmd=new OleDbCommand("select * from news where id="+id,con);
oddr=cmd.ExecuteReader();
 
oddr.Read();
string s=oddr["title"].ToString()+"|"+oddr["content"].ToString()+"|"+oddr["author"].ToString()+"|"+oddr["time"].ToString();
oddr.Close();
string []sa=s.Split(char.Parse("|"));
return sa;
}
finally
{
con.Close();

}

}
// public string[] GetNews(int id)
// {
// OleDbConnection con=CreateCon();
// con.Open();
// try
// {
// OleDbCommand cmd=new OleDbCommand("select * from news where id="+id);
// OleDbDataReader oddr=cmd.ExecuteReader();
// oddr.Read();
//
// string s=oddr["title"].ToString()+"|"+oddr["author"].ToString()+"|"+oddr["content"].ToString();
// oddr.Close();
// con.Close();
// string[] sa=s.Split('|');
// return  sa;
// }
// finally
// {
// con.Close();
// }
//
//
// }
另外还有一个问题就是: