hello,everybody! I want to ask a question about database this is my asp.net program : <script Language="VB" Runat="Server"> sub Page_Load(Sender As Object, E As EventArgs) dim ds as new dataset dim olecon as oledbconnection dim oledr as oledbdataadapter olecon=new
oledbconnection("provider=microsoft.jet.oledb.4.0; datasource=d:\wangzhan\db1.mdb") oledr=new oledbdataadapter("select * from jigoushezhi",olecon) ds = new DataSet() oledr.Fill(ds, "jigoushezhi") mydatagrid.DataSource=ds.Tables("jigoushezhi").DefaultView mydatagrid.DataBind()
end sub </script> why the syetem always show the error message :dont'found the "ISAM"?
Try this: dim ds as new dataset dim olecon as oledbconnection dim oledr as oledbdataadapter olecon=new oledbconnection("Provider=Microsoft.Jet.OLEDB.4.0;Data Source=d:\wangzhan\db1.mdb") oledr=new oledbdataadapter("select * from employees",olecon) ds = new
DataSet() oledr.Fill(ds, "jigoushezhi") mydatagrid.DataSource=ds.Tables("jigoushezhi").DefaultView mydatagrid.DataBind() look at the way Data Source looks, compared to yours
georage
Member
5 Points
1 Post
The question about "databind()"
Sep 16, 2003 07:57 AM|LINK
augustwind
All-Star
35860 Points
4900 Posts
ASPInsiders
Moderator
Re: The question about "databind()"
Sep 16, 2003 01:44 PM|LINK
All Things Dot Net
Stored Procs and Code in a Flash!
ASP.Net Sitemap Creator