|
-
May 1st, 2003, 01:04 PM
#1
Thread Starter
Frenzied Member
Link
Is there a way to create SQL link in Access using VBA?
Last edited by Liquid Metal; May 1st, 2003 at 01:08 PM.
I'll Be Back!
T-1000
Microsoft .Net 2005
Microsoft Visual Basic 6
Prefer using API
-
May 1st, 2003, 01:08 PM
#2
Let me in ..
Re: Link
Originally posted by Liquid Metal
Is there a way to create SQL link in Access?
Yes just right click in access db and select data links ... then use a sql provider and specify the destination.
-
May 1st, 2003, 01:15 PM
#3
Thread Starter
Frenzied Member
I know how to do that. I was referring to do it with VBA.
I'll Be Back!
T-1000
Microsoft .Net 2005
Microsoft Visual Basic 6
Prefer using API
-
May 1st, 2003, 02:08 PM
#4
Thread Starter
Frenzied Member
Thanks anyway Techyspecy
Here is the solution.
Code:
DoCmd.RunSQL ("DROP TABLE TestTable1")
DoCmd.SetWarnings False
DoCmd.TransferDatabase acLink, "ODBC Database", "ODBC;DSN=LocalServer;DATABASE=Test", acTable, "Table1", "TestTable1"
DoCmd.SetWarnings True
I'll Be Back!
T-1000
Microsoft .Net 2005
Microsoft Visual Basic 6
Prefer using API
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|