在线时间:8:00-16:00
迪恩网络APP
随时随地掌握行业动态
扫描二维码
关注迪恩网络微信公众号
DataSet ds = new DataSet(); OleDbConnection con; OleDbDataAdapter myadapter; con = new OleDbConnection(str); con.Open(); myadapter = new OleDbDataAdapter("select * from [Sheet1$]", con); myadapter.Fill(ds, "ds"); foreach (DataRow row in ds.Tables["ds"].Rows) { string userInfo = row[0].ToString().Trim() + row[1].ToString().Trim() + row[2].ToString().Trim() + row[3].ToString().Trim() + row[4].ToString().Trim(); Response.Write(userInfo); } con.Close(); |
请发表评论