Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default Import Data from Access Database in a Workgroup

H!,

Hope someone can help me, I've been trying to figure
this out all day. I have a Database on this Path:
C:\AssetTracker\Access 2000
\MMH_CIL_RevN_Cnvrtd.mdb /Wrkgrp \\owgn1mmd\mmh_pm2
\Asset_Tracker\CIL2000Compacted.mdw /Nostartup.

I want to import the data from an Access 2000 database
table to an Excel 2000 worksheet. The database is
password protected and part of a workgroup. I've tried
the Wizard, Modifying the .dsn file & attempted to do it
by creating a VB function. No dice.

Thanx
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 14
Default Import Data from Access Database in a Workgroup

Use the SystemDB property of the DBEngine Object.

e.g.

Sub TestCxn()

Dim ws As Workspace
Dim db As Database

DBEngine.SystemDB = "\\owgn1mmd\mmh_pm2\Asset_Tracker\CIL2000Compacted .mdw"
Set ws = CreateWorkspace("", "userID", "password")
Set db = ws.OpenDatabase("C:\AssetTracker\Access
2000\MMH_CIL_RevN_Cnvrtd.mdb ", True)
Debug.Print db.TableDefs.Count

db.Close
ws.Close

End Sub


Replace userID and password with your credentials. If your access is
validated, the db's tablecount will be displayed in the immediate window. If
not, you'll get an error.

From here you can open whatever recordsets you need to get the data into xl
(as long as you have the appropriate permissions).

Cheers,
HWH


"David" wrote in message
...
H!,

Hope someone can help me, I've been trying to figure
this out all day. I have a Database on this Path:
C:\AssetTracker\Access 2000
\MMH_CIL_RevN_Cnvrtd.mdb /Wrkgrp \\owgn1mmd\mmh_pm2
\Asset_Tracker\CIL2000Compacted.mdw /Nostartup.

I want to import the data from an Access 2000 database
table to an Excel 2000 worksheet. The database is
password protected and part of a workgroup. I've tried
the Wizard, Modifying the .dsn file & attempted to do it
by creating a VB function. No dice.

Thanx



Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

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


Similar Threads
Thread Thread Starter Forum Replies Last Post
database query not showing foxpro database How I import data mangat New Users to Excel 1 June 24th 07 03:31 PM
Database query to import from Access to Excel David T Excel Discussion (Misc queries) 0 August 31st 06 07:12 PM
How to import multiple sheet of excel into Access database to a diffrent tables?? baka Excel Discussion (Misc queries) 0 July 6th 06 05:48 AM
MS JET database engine error: workgroup information file is missing or opened exclusively by another user Tina Excel Discussion (Misc queries) 0 August 24th 05 01:40 AM
Excel error while trying to import data from an Access database - MSQRY32.exe has generated errors X_HOBBES Excel Discussion (Misc queries) 0 March 15th 05 06:46 PM


All times are GMT +1. The time now is 06:15 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"