Results 1 to 12 of 12

Thread: [Resolved] MS Access Database and (dynamic) Connection String

Threaded View

  1. #1

    Thread Starter
    Junior Member
    Join Date
    Aug 2005
    Posts
    28

    [Resolved] MS Access Database and (dynamic) Connection String

    Hey all,
    I'm working on creating an installation package for my program. It includes an MS Access database, and I've just been using an ODBC connection to connect to it. I was building the connection string on the basis that I had a defineable location for the database. Now I need the connection string to just look for the file in the same folder that the installation was made to (and also the same folder that the .exe and other files will be in).
    Here is the connection string I'm using now:

    Provider=MSDASQL.1;Persist Security Info=False;Extended Properties="DSN=MS Access Database;DBQ=C:\Documents and Settings\JP\My Documents\Visual Studio Projects\BrickBlaster\levels.mdb;DefaultDir=C:\Documents and Settings\JP\My Documents\Visual Studio Projects\BrickBlaster;DriverId=25;FIL=MS Access;MaxBufferSize=2048;PageTimeout=5;UID=admin;"

    I guess what I'm asking is what do I change the DBQ= and DefaultDir= to?
    Last edited by Sgt Spike; Oct 4th, 2006 at 12:17 PM.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width