Dynaset gone in Windows 2003?

Q

quartz

I recently had Windows 2003 installed, but my Access version did not change
(XP). I noticed that now I cannot dim a variable as a "Dynaset", it no longer
even auto-senses this type.

I have DAO 3.6 library referenced (NOTE: please do not tell me to use ADO
instead) how do I fix this issue so that many in place programs will run?

Thanks much in advance.
 
Q

quartz

Dan, thanks, by that do you mean: Microsoft DAO 3.51 Object Libary?

If so, auto-sensing still doesn't pick it up...what am I doing wrong?
 
D

Dan Artuso

Hi,
No, remove the reference to Microsoft DAO 3.51 Object Libary and add
one to DAO 2.5/3.51 Compatability Library. That's where the Dynaset lives.
I do recommend revising your legacy code though. You can declare the objects
as Recordsets and just make the type Dynaset if you wish. Then you can just use
DAO 3.51
 
D

Douglas J. Steele

Don't think he can do that, Dan: he's using Access 2002. I thought 97 was
the last version that supported the Compatability Library.
 
P

Paul Overway

Yes...97 was the last version to support the compatibility library. And
dynaset goes back to versions 1 & 2. So, he really has some old
code...which must be updated.
 
J

Joe Fallon

I recently converted an old A97 app (originally written in Access 2.0) to
A2003 and hit this issue.
I removed the reference to the compatibility library and added a standard
DAO 3.6 reference instead and then edited the code to change Dynaset to
Recordset.

e.g.
=============================================
Dim MyDyna As Dynaset
became:
Dim rs As Recordset
=============================================
Set MyDyna = MyDB.CreateDynaset(tableName)
became:
Set rs = db.OpenRecordset(tableName, dbOpenDynaset)
=============================================
MyDyna.MoveFirst
became:
rs.MoveFirst
=============================================
myFunction= MyDyna(Expr$)
became:
GetFirst = rs(Expr)
=============================================
 
Q

quartz

Thanks much to all who responded. All input was helpful. FYI, I typically use
ADO.

The "legacy" code is inherited and I am updating as I find it. It is riddled
throughout the organization and can only be updated (and uncovered) as users
report issues. Due to time constraints, it sometimes quicker to apply a
bandaid, thus my OP.

Again, thanks for the input.
 
Top