If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

 
Go Back  dBforums > Database Server Software > Pervasive.SQL > Excel Connection to Timberline

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old 02-25-09, 19:52
Andystoys Andystoys is offline
Registered User
 
Join Date: Feb 2009
Posts: 2
Excel Connection to Timberline

I am looking for the VBA code to connect to a timberline database. I have an Excel workbook that queries Timberline via msquery. I have a macro that refreshes the data when run. I want to make the connection prior to the refresh and provide user id and password in the macro so the user is not prompted. Any help would be appreciated.
Reply With Quote
  #2 (permalink)  
Old 02-27-09, 15:26
Andystoys Andystoys is offline
Registered User
 
Join Date: Feb 2009
Posts: 2
Well, maybe I posted in the wrong place or this wasn't difficult enough for anyone to help with but no one answered so I kept working on this and figured it out. Since 60 something people viewed it I'm posting the code in case anyone else needs it. Just modify the database location to your own. This is all on one line of code. There are no spaces even though it appears there are when I look at it in this post.

ActiveSheet.QueryTables(1).Connection = "ODBC;DSN=Timberline Data Source;UID=xxxx;PWD=xxxx;;DBQ=c:\datafolder;CODEPA GE=1252;MaxColSupport=1500;DictionaryMode=0;Standa rdMode=1;MaxColSupport=1500;ShortenNames=1;Databas eType=1;"

Last edited by Andystoys; 02-27-09 at 15:33.
Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
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

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