DAO - VC++ 6 - 0x80041002

We have a legacy C++ app that needs to work with Access 97 mdb files, and uses the CDao classes from MFC. Recently, the need has arisen to make a few changes to this app. But, when I build the project without changes, I am getting errors. Specifically, 0x80041002 from CDaoRecordSet::Open(). The mdb file is present, and has already been updated by the same program, prior to this event. I can't discern any error message. The query looks like this:

SELECT * FROM Rule WHERE ((Product_ID = %d) AND (Section_Level = 0)) ORDER BY Rule_Order ASC

This table contains an AutoNumber field.

What's changed in the development machine? Quite a lot, potentially. XP SP3, Office 2007, IE 7, at a minimum.

Does this situation ring a bell with anyone?

Thanks,
Art
It's WBEM_E_NOT_FOUND.

You may find this link helpful, you'll need to follow the thread.
http://www.tech-archive.net/Archive/Development/microsoft.public.win32.programmer.wmi/2005-08/msg00119.html
Folks, I blush to say that I have found the problem, and that it is within the application. DAO was trying to tell me that I had one fewer columns in my table than I thought I did. Why did it not fail for the users? They have a version older than this bug.

Apologies to anyone who spent time thinking about this.
Topic archived. No new replies allowed.