Solved

Create DSN to access a Paradox database

Posted on 2001-07-20
2
476 Views
Last Modified: 2010-05-18
Using VB, I would like to create a DSN for a paradox database. Then, I will use it to access the paradox data (creating an ADO database connection).
Does anyone have a script to create the DSN (full registry entry)?
0
Comment
Question by:pyeloy
  • 2
2 Comments
 
LVL 8

Expert Comment

by:Dave_Greene
ID: 6302947
Why don't you just use a .reg file

Copy this to a file called "para.reg"  then double click it..  and your DSN has been created.  Modify as needed

<FILE START>

REGEDIT4

[HKEY_LOCAL_MACHINE\SOFTWARE\ODBC\ODBC.INI\ParaDox]
"Driver"="C:\\WINNT\\System32\\odbcjt32.dll"
"Description"="New DSN"
"DriverId"=dword:0000021a
"FIL"="Paradox 5.X;"
"SafeTransactions"=dword:00000000
"UID"="C01395"

[HKEY_LOCAL_MACHINE\SOFTWARE\ODBC\ODBC.INI\ParaDox\Engines]

[HKEY_LOCAL_MACHINE\SOFTWARE\ODBC\ODBC.INI\ParaDox\Engines\Paradox]
"CollatingSequence"="ASCII"
"ImplicitCommitSync"=""
"PageTimeout"=dword:00000258
"ParadoxNetPath"="C:\\WINNT\\System32"
"ParadoxNetStyle"="4.x"
"ParadoxUserName"="C01395"
"Threads"=dword:00000003
"UserCommitSync"="Yes"

<FILE END>

Here is a DSN-Less Connection too...
oConn.Open "Driver={Microsoft Paradox Driver (*.db)};" & _
                   "DriverID=538;" & _
                   "Fil=Paradox 5.X;" & _
                   "DefaultDir=c:\dbpath\;" & _
                   "Dbq=c:\dbpath\;" & _
                   "CollatingSequence=ASCII;"

0
 
LVL 8

Accepted Solution

by:
Dave_Greene earned 50 total points
ID: 6302950
Then when you deploy you application, just add your .reg file into the setup and your users DSN will be created by the setup program  :)

Cheers
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Most everyone who has done any programming in VB6 knows that you can do something in code like Debug.Print MyVar and that when the program runs from the IDE, the value of MyVar will be displayed in the Immediate Window. Less well known is Debug.Asse…
You can of course define an array to hold data that is of a particular type like an array of Strings to hold customer names or an array of Doubles to hold customer sales, but what do you do if you want to coordinate that data? This article describes…
As developers, we are not limited to the functions provided by the VBA language. In addition, we can call the functions that are part of the Windows operating system. These functions are part of the Windows API (Application Programming Interface). U…
This lesson covers basic error handling code in Microsoft Excel using VBA. This is the first lesson in a 3-part series that uses code to loop through an Excel spreadsheet in VBA and then fix errors, taking advantage of error handling code. This l…

863 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

22 Experts available now in Live!

Get 1:1 Help Now