C#高级编程: 数据库的绑定[2]
发表于:2008-05-16来源:作者:点击数:
标签:数据库高级绑定
关键字: .net public class WebForm1 : System.Web.UI.Page { ... protected System.Data.DataSet ds; protected System.Data.DataTable eventTable; protected System.Data.OleDb.OleDbDataAdapter daAttendees; protected System.Data.OleDb.OleDbDataAdap
关键字:
.net public class WebForm1 : System.Web.UI.Page
{
...
protected System.Data.DataSet ds;
protected System.Data.DataTable eventTable;
protected System.Data.OleDb.OleDbDataAdapter daAttendees;
protected System.Data.OleDb.OleDbDataAdapter daRooms;
protected System.Data.OleDb.OleDbDataAdapter daEvents;
提示:所有OLE DB对象都有SQL Server版本,它们的用法也是一样的。
Page_Load()现在需要创建DataSet对象:
private void Page_Load(object sender, System.EventArgs e)
{
oleDbConnection1.Open();
ds = new DataSet();
原文转自:http://www.ltesting.net