dbTalk Databases Forums  

Novice question ADO

comp.database.ms-access comp.database.ms-access


Discuss Novice question ADO in the comp.database.ms-access forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
Steve Laycock
 
Posts: n/a

Default Novice question ADO - 12-27-2004 , 06:18 PM






I want to use VB to add /remove/ display data table records "by hand".
When I type a line like
SET myDbs = CurrentDB
the debugger informs me that CurrentDB is an unknown object.

Thinking that this meant that ADO objects had not been installed on my PC I
downloaded MDAC_TYP.exe from the MSDN site and tried to install it. The
installation aborted after telling me that XP PRO Service Pack 2 already
current in the OS.

I also cannot use the older DAO way of doing things because it has no idea
what a 'Database' type object is.

Thanks in advance



Reply With Quote
  #2  
Old   
Ken Snell
 
Posts: n/a

Default Re: Novice question ADO - 12-29-2004 , 10:23 AM






CurrentDb is a DAO-related function, not ADO. Likely you need to set
reference to DAO library in your ACCESS file. Do this by switching to Visual
Basic Editor (Alt-F11), then click Tools | References, and set a reference
to DAO library.

--

Ken Snell
<MS ACCESS MVP>

"Steve Laycock" <slaycock (AT) bigpond (DOT) net.au> wrote

Quote:
I want to use VB to add /remove/ display data table records "by hand".
When I type a line like
SET myDbs = CurrentDB
the debugger informs me that CurrentDB is an unknown object.

Thinking that this meant that ADO objects had not been installed on my PC
I downloaded MDAC_TYP.exe from the MSDN site and tried to install it. The
installation aborted after telling me that XP PRO Service Pack 2 already
current in the OS.

I also cannot use the older DAO way of doing things because it has no idea
what a 'Database' type object is.

Thanks in advance





Reply With Quote
  #3  
Old   
Steve Laycock
 
Posts: n/a

Default Re: Novice question ADO - 12-31-2004 , 06:51 PM



Thanks for that Ken - it's the little things that'll drive you crazy

"Ken Snell" <kthsneisllis9 (AT) ncoomcastt (DOT) renaetl> wrote

Quote:
CurrentDb is a DAO-related function, not ADO. Likely you need to set
reference to DAO library in your ACCESS file. Do this by switching to
Visual Basic Editor (Alt-F11), then click Tools | References, and set a
reference to DAO library.

--

Ken Snell
MS ACCESS MVP

"Steve Laycock" <slaycock (AT) bigpond (DOT) net.au> wrote in message
newsD1Ad.90714$K7.58480 (AT) news-server (DOT) bigpond.net.au...
I want to use VB to add /remove/ display data table records "by hand".
When I type a line like
SET myDbs = CurrentDB
the debugger informs me that CurrentDB is an unknown object.

Thinking that this meant that ADO objects had not been installed on my PC
I downloaded MDAC_TYP.exe from the MSDN site and tried to install it. The
installation aborted after telling me that XP PRO Service Pack 2 already
current in the OS.

I also cannot use the older DAO way of doing things because it has no
idea what a 'Database' type object is.

Thanks in advance







Reply With Quote
Reply




Thread Tools
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

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.3
Copyright ©2000 - 2010, Jelsoft Enterprises Ltd.