Wrox Programmer Forums

Need to download code?

View our list of code downloads.

Go Back   Wrox Programmer Forums > ASP.NET and ASP > Other ASP.NET > ASP.NET 1.x and 2.0 Application Design
Password Reminder
Register
| FAQ | Members List | Search | Today's Posts | Mark Forums Read
ASP.NET 1.x and 2.0 Application Design Application design with ASP.NET 1.0, 1.1, and 2.0.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the ASP.NET 1.x and 2.0 Application Design section of the Wrox Programmer to Programmer discussions. This is a community of tens of thousands of software programmers and website developers including Wrox book authors and readers. As a guest, you can read any forum posting. By joining today you can post your own programming questions, respond to other developers’ questions, and eliminate the ads that are displayed to guests. Registration is fast, simple and absolutely free .
DRM-free e-books 300x50
 
 
Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old June 15th, 2004, 03:59 PM
Registered User
 
Join Date: Jun 2004
Location: , , .
Posts: 2
Thanks: 0
Thanked 0 Times in 0 Posts
Default 'Microsoft.Jet.OLEDB4.0' provider not registere

hi,
   I am new to ASP.net. I am trying out an example of using Access database from ASP.net. But when I am trying to access the page, I am getting the following error.

[OleDbException (0x80040154): No error information available: REGDB_E_CLASSNOTREG(0x80040154).]

[InvalidOperationException: The 'Microsoft.Jet.OLEDB4.0' provider is not registered on the local machine.]
   System.Data.OleDb.OleDbConnection.CreateProviderEr ror(Int32 hr) +83
   System.Data.OleDb.OleDbConnection.CreateProvider(O leDbConnectionString constr) +107
   System.Data.OleDb.OleDbConnection.Open() +203
   System.Data.Common.DbDataAdapter.QuietOpen(IDbConn ection connection, ConnectionState& originalState) +44
   System.Data.Common.DbDataAdapter.FillFromCommand(O bject data, Int32 startRecord, Int32 maxRecords, String srcTable, IDbCommand command, CommandBehavior behavior) +304
   System.Data.Common.DbDataAdapter.Fill(DataSet dataSet, Int32 startRecord, Int32 maxRecords, String srcTable, IDbCommand command, CommandBehavior behavior) +77
   System.Data.Common.DbDataAdapter.Fill(DataSet dataSet, String srcTable) +36
   ASP.datacontrol1_aspx.Page_Load(Object Sender, EventArgs E) in C:\BegASPNET\Ch01\datacontrol1.aspx:21
   System.Web.UI.Control.OnLoad(EventArgs e) +67
   System.Web.UI.Control.LoadRecursive() +35
   System.Web.UI.Page.ProcessRequestMain() +731

If anyone can help me with this error, it would be great.

thank you,
Satya.

  #2 (permalink)  
Old June 15th, 2004, 04:06 PM
Friend of Wrox
Points: 3,489, Level: 24
Points: 3,489, Level: 24 Points: 3,489, Level: 24 Points: 3,489, Level: 24
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Jun 2003
Location: Central, NJ, USA.
Posts: 1,102
Thanks: 0
Thanked 2 Times in 2 Posts
Default

Id' move this question to the Access forum... or the ASPX forum...


Hal Levy
Web Developer, PDI Inc.

NOT a Wiley/Wrox Employee
  #3 (permalink)  
Old June 16th, 2004, 04:36 AM
Friend of Wrox
Points: 3,558, Level: 25
Points: 3,558, Level: 25 Points: 3,558, Level: 25 Points: 3,558, Level: 25
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Jun 2003
Location: California, USA
Posts: 996
Thanks: 2
Thanked 11 Times in 11 Posts
Send a message via Yahoo to melvik
Default

If u use Access fro ur ASP pages asa DataSet u r in right place!
but about ur question, can u plz send ur Code insted of error!

Always:),
Hovik Melkomian.
  #4 (permalink)  
Old June 16th, 2004, 04:29 PM
Registered User
 
Join Date: Jun 2004
Location: , , .
Posts: 2
Thanks: 0
Thanked 0 Times in 0 Posts
Default

hi,
  Here's the code for my program.


<%@ Page Language="vb" debug="true" %>
<%@ Import Namespace="System.Data" %>
<%@ Import Namespace="System.Data.OleDb" %>
<script language="vb" runat="server">
Sub Page_Load(Sender As Object, E as EventArgs)

    Dim objConnection as OleDbConnection
    Dim objCommand As OleDbDataAdapter
    Dim strConnect As String
    Dim strCommand As String
    Dim DataSet1 As New DataSet

    strConnect = "Provider=Microsoft.Jet.OLEDB4.0;"
    strConnect += "Data Source=C:\BegASPNET\Ch02\grocertogo.mdb;"
    strConnect += "Persist Security Info=False"

    strCommand = "SELECT ProductName, UnitPrice FROM products"
    objConnection = New OleDbConnection(strConnect)
    objCommand = New OleDbDataAdapter(strCommand, objConnection)
    objCommand.Fill(DataSet1, "products")
    DataGrid1.DataSource=DataSet1.Tables("Products").D efaultView
    DataGrid1.DataBind()
End Sub
</script>

<html>
<head>
 <title> Data Grid Control example </title>
</head>

<body>
<asp:DataGrid id="DataGrid1" runat="server" />
</body>
</html>


thank you,
Satya.

  #5 (permalink)  
Old June 17th, 2004, 02:08 AM
Imar's Avatar
Wrox Author
Points: 72,073, Level: 100
Points: 72,073, Level: 100 Points: 72,073, Level: 100 Points: 72,073, Level: 100
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Jun 2003
Location: Utrecht, Netherlands.
Posts: 17,089
Thanks: 80
Thanked 1,587 Times in 1,563 Posts
Default

Hi there,

I think you're missing a dot between OleDb and 4.0:

strConnect = "Provider=Microsoft.Jet.OLEDB.4.0;"
strConnect += "Data Source=C:\BegASPNET\Ch02\grocertogo.mdb;"
strConnect += "Persist Security Info=False"

When in doubt with your connection strings, check out this page:

http://www.able-consulting.com/ADO_Conn.htm

Cheers,

Imar
---------------------------------------
Imar Spaanjaars
Everyone is unique, except for me.
  #6 (permalink)  
Old June 17th, 2004, 03:10 AM
Friend of Wrox
Points: 3,558, Level: 25
Points: 3,558, Level: 25 Points: 3,558, Level: 25 Points: 3,558, Level: 25
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Jun 2003
Location: California, USA
Posts: 996
Thanks: 2
Thanked 11 Times in 11 Posts
Send a message via Yahoo to melvik
Default

Yes Exactly u r right Imar! it should be
Code:
"...Provider=Microsoft.Jet.OLEDB.4.0;..."
In other hand I suggest to use
Code:
[u]Server.MapPath</u>
Always:),
Hovik Melkomian.
 


Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Microsoft Jet connection problem istcomnet BOOK: Beginning ASP 3.0 3 February 27th, 2013 09:31 AM
Microsoft JET Database Engine (0x80040E07) gwalker_ne8 Classic ASP Databases 2 November 11th, 2006 09:32 AM
Microsoft JET Database Engine (0x80004005) kenh BOOK: Beginning ASP 3.0 4 April 6th, 2005 08:52 AM
Permission Request from Microsoft Jet Provider Griffinite Classic ASP Databases 5 December 17th, 2004 01:28 PM



All times are GMT -4. The time now is 08:39 AM.


Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
© 2013 John Wiley & Sons, Inc.