Geekzone: technology news, blogs, forums
Guest
Welcome Guest.
You haven't logged in yet. If you don't have an account you can register now.


teasp00n

28 posts

Geek


#84236 27-May-2011 07:11
Send private message

I am currently trying to figure out why my software refuses to run on Windows 7 x64 Home Premium.

When a user tries to log in the software queries a .mdb to authenticate the user however it will throw the following error:

"System.InvalidOperationException: The .Net Framework Data Providers require Microsoft Data Access Components (MDAC). Please install MDAC version 2.6 or later."

On face value it seems like an easy fix (and maybe is for some of you ;)) but MDAC is no longer supported in Windows Vista or Windows 7 being replaced by Windows Data Access Components (WDAC), which to my knowledge, are built into the core directly.

Currently I have 2 scenarios in mind:

1: Windows 7 Home Premium does not include some of the data access components required by the software with the solution being upgrading my licence to Professional or higher.

2: The software is trying to use a legacy data provider that is no longer supported in WDAC. The connection string I am using is: "Provider=Microsoft.Jet.OLEDB.4.0; Data Source=pathtodb.mdb";

According to my research that connection string is OK.

I should also mention that this works on a system running Windows 7 x86 Professional edition.

Any help with this would be greatly appreciated.

Troy 

View this topic in a long page with up to 500 replies per page Create new topic
 1 | 2
gcorgnet
1078 posts

Uber Geek


  #474661 27-May-2011 08:21
Send private message

Hi,

I am assuming you are referring to a software you are developing yourself, right?

Do you HAVE to use the jet provider?
I had success accessing a mdb database using more recent providers like Microsoft.ACE.OLEDB.14.0.
(There is also a version 12, not sure which one you need)

This page here should let you download installers for the providers (choose x64)



teasp00n

28 posts

Geek


  #474662 27-May-2011 08:24
Send private message

Yeah it's software I am developing.

No I don't have to use Jet, in fact I was actually looking for an alternative the other day but all the examples I found were indicating Jet. 

Thanks for your help I'll give that a go.

Troy 

TwoSeven
1623 posts

Uber Geek

Subscriber

  #474666 27-May-2011 08:54
Send private message

You might find your connection string will be the issue.

Couple of things I would try would be to use Provider=OLEDB or to drop the .4.0 part of your existing provider string. Also you may need to specify a Driver clause.




Software Engineer
   (the practice of real science, engineering and management)
A.I.  (Automation rebranded)
Gender Neutral
   (a person who believes in equality and who does not believe in/use stereotypes. Examples such as gender, binary, nonbinary, male/female etc.)

 

 ...they/their/them...




teasp00n

28 posts

Geek


  #475027 28-May-2011 02:21
Send private message

I tried this, no joy.

I tried installing the x64 ODBC driver and it said I couldn't as I already had 32 bit office products installed so I installed the 32bit driver. It gave me the same error as in my original post. I then uninstalled office and the 32 bit driver so I could install the 64 bit driver and again, same error.

I know the provider (Microsoft.ACE.OLDB.12.0) works as I installed the driver on my dev pc (running xp) and tested them and everything works fine. I also tested the new provider on the 32bit Windows 7 Professional machine that was working with the previous data providers and it worked fine there too.

The only thing I can think of now is the difference in the licence (Home Premium vs Professional). How likely is it that this is causing my problem? Is it possible Home Premium doesn't ship with some of the data access components? Initially I thought so but the more I think about it the less possible it seems but I don't know what else it could be except perhaps I need to compile for 64bit architecture, install the 64bit drivers and buy 64bit office (didn't think this was necessary. Most of the apps I install on my 64bit pc are 32 bit binaries and they all work fine).

EDIT: I have googled this quite extensively and everyone who is reporting similar issues is using some Home Premium licence whether it be Vista or 7...  

gzt

gzt
17106 posts

Uber Geek

Lifetime subscriber

  #475068 28-May-2011 11:11
Send private message

No idea. It's been a while, but I recall MDAC was a constant nightmare across different platforms.

Some suggestions:

Home premium cannot join a domain - which can impact some security/permissions related things which can have strange and unexpected consequences:


  • Try putting the mdb into a user directory like 'my documents'

  • Try disabling UAC

  • Have a close look at the Data sources (ODBC) in Administrative Tools

  • Specify a user name and password even if you do not need one


Also, maybe a later Access redistributable will magically resolve the situation.


gzt

gzt
17106 posts

Uber Geek

Lifetime subscriber

  #475072 28-May-2011 11:35
Send private message

This is interesting: http://support.microsoft.com/kb/942976

"If you build and then run an application as a 32-bit application on a 64-bit operating system, you must create the ODBC data source by using the ODBC Administrator tool in %windir%\SysWOW64\odbcad32.exe."

TwoSeven
1623 posts

Uber Geek

Subscriber

  #475155 28-May-2011 16:04
Send private message

Adding to my earlier post, I am assuming your database in a Microsft Access one, but you do not state what programming language your application is developed in.

I have found that the issue often comes down to an incorrect connection string.

A OLE DB connection string provider contains the provider name and version to use (progId) for example Jet.4.0 refers to jet version 4.0 (assuming you have that version installed. The ProgId is optional, if not specified the most recent version of the driver will be used. I suspect this is your issue.

The first thing I would do is remove the progId portion from the connection string, if that does not work, I would try a different provider (such as OLEDB).

You may also need to apply the driver property to the connection string if you want to use a specific driver (the Driver= clause).





Software Engineer
   (the practice of real science, engineering and management)
A.I.  (Automation rebranded)
Gender Neutral
   (a person who believes in equality and who does not believe in/use stereotypes. Examples such as gender, binary, nonbinary, male/female etc.)

 

 ...they/their/them...


 
 
 

Cloud spending continues to surge globally, but most organisations haven’t made the changes necessary to maximise the value and cost-efficiency benefits of their cloud investments. Download the whitepaper From Overspend to Advantage now.
teasp00n

28 posts

Geek


  #475160 28-May-2011 16:12
Send private message

OK good advice, thanks. 

It is developed in C#

Ill give it a go on Monday.  

Ragnor
8219 posts

Uber Geek

Trusted

  #475305 29-May-2011 01:41
Send private message

If you are considering changing the database I would recommend http://www.sqlite.org/

The .NET adapter/library for it is here http://system.data.sqlite.org/

teasp00n

28 posts

Geek


  #476896 2-Jun-2011 05:06
Send private message

Sorry for taking so long to post feedback, got busy fixing something else :P

I think it may actually be because it has been compiled in VS 2008 for "Any CPU". I've read that this can cause issues when it tries to load 32 bit drivers from a 64 bit application (which it will be).

EDIT: Similar to what gzt mentioned above.

gzt

gzt
17106 posts

Uber Geek

Lifetime subscriber

  #476963 2-Jun-2011 10:25
Send private message

Thanks for the update, I like to keep up with MDAC issues. If you can confirm targeting x86 if you have the opportunity. ;  ) 

TwoSeven
1623 posts

Uber Geek

Subscriber

  #477212 2-Jun-2011 21:10
Send private message

teasp00n: Sorry for taking so long to post feedback, got busy fixing something else :P

I think it may actually be because it has been compiled in VS 2008 for "Any CPU". I've read that this can cause issues when it tries to load 32 bit drivers from a 64 bit application (which it will be).

EDIT: Similar to what gzt mentioned above.


Is this a web-app? 




Software Engineer
   (the practice of real science, engineering and management)
A.I.  (Automation rebranded)
Gender Neutral
   (a person who believes in equality and who does not believe in/use stereotypes. Examples such as gender, binary, nonbinary, male/female etc.)

 

 ...they/their/them...


Regs
4066 posts

Uber Geek

Trusted
Snowflake

  #477252 2-Jun-2011 22:50
Send private message

we built something that needed to be targeted specifically at x86 because it wouldnt work when we dropped it on x64 platform - it was also trying to reference an ODBC driver. Probably the same issue. Default was initialy Any CPU.




teasp00n

28 posts

Geek


  #477276 3-Jun-2011 06:40
Send private message

Hey guys,

Quick update; I have tried running the program targeted for x86 with various combinations of the connection strings provided in previous posts. This hasn't worked :/

It still complains about the msdart.dll and I'm starting to think that this might be corrupt. I'll have a go at replacing the dll and re registering it.

EDIT: No it's a desktop application. 

gzt

gzt
17106 posts

Uber Geek

Lifetime subscriber

  #477279 3-Jun-2011 06:59
Send private message

teasp00n: It still complains about the msdart.dll [...] 

What is the exact error message there?

 1 | 2
View this topic in a long page with up to 500 replies per page Create new topic





News and reviews »

Air New Zealand Starts AI adoption with OpenAI
Posted 24-Jul-2025 16:00


eero Pro 7 Review
Posted 23-Jul-2025 12:07


BeeStation Plus Review
Posted 21-Jul-2025 14:21


eero Unveils New Wi-Fi 7 Products in New Zealand
Posted 21-Jul-2025 00:01


WiZ Introduces HDMI Sync Box and other Light Devices
Posted 20-Jul-2025 17:32


RedShield Enhances DDoS and Bot Attack Protection
Posted 20-Jul-2025 17:26


Seagate Ships 30TB Drives
Posted 17-Jul-2025 11:24


Oclean AirPump A10 Water Flosser Review
Posted 13-Jul-2025 11:05


Samsung Galaxy Z Fold7: Raising the Bar for Smartphones
Posted 10-Jul-2025 02:01


Samsung Galaxy Z Flip7 Brings New Edge-To-Edge FlexWindow
Posted 10-Jul-2025 02:01


Epson Launches New AM-C550Z WorkForce Enterprise printer
Posted 9-Jul-2025 18:22


Samsung Releases Smart Monitor M9
Posted 9-Jul-2025 17:46


Nearly Half of Older Kiwis Still Write their Passwords on Paper
Posted 9-Jul-2025 08:42


D-Link 4G+ Cat6 Wi-Fi 6 DWR-933M Mobile Hotspot Review
Posted 1-Jul-2025 11:34


Oppo A5 Series Launches With New Levels of Durability
Posted 30-Jun-2025 10:15









Geekzone Live »

Try automatic live updates from Geekzone directly in your browser, without refreshing the page, with Geekzone Live now.



Are you subscribed to our RSS feed? You can download the latest headlines and summaries from our stories directly to your computer or smartphone by using a feed reader.