|
-
November 3rd, 1999, 09:24 AM
#1
How to add an ODBC data source during setup?
I use VB6 and MS Access. I want to add an ODBC data source during setup or the first time the program runs. I know I can do it manually by going to Start-Settings-COntrol Panel-ODBC Data Sources, but I want it achieved in programs. Does anybody know the API to do this in VB or InstallShield? Thank you very mcuh!
-
November 3rd, 1999, 09:30 AM
#2
Re: How to add an ODBC data source during setup?
if you use a FILE DSN instead of a user or system DSN you won't need to use an API or access the Control panel.
Simply create a FILE DSN on your development machine and include it in your setup.
-
November 3rd, 1999, 09:35 AM
#3
Re: How to add an ODBC data source during setup?
Do you mean that setup will automatically add that DSN into ODBC Data Sources if that DSN does not exist in user's machine?
-
November 3rd, 1999, 09:38 AM
#4
Re: How to add an ODBC data source during setup?
kind of.
As far as FileDSNs are concerned, the control panel applet will look in a certain folder to see if there are any file DSNs (don't remember the exact folder path).
Anyway, you can place yoUR FILEDSNFile anywhere you want, provided that you specify the path to that file DSN file in your connectionstring.
-
November 3rd, 1999, 10:06 AM
#5
Re: How to add an ODBC data source during setup?
I looked Help and it says I can create a FILE DSN by right-click the database project I want to add a data connection to, and then select Add Data Connection. But I can not find it.
My problem is that I need to tell Crystal Report a DSN which is in my development machine, but I want to make it appear in user's machine as well.
-
November 3rd, 1999, 10:09 AM
#6
Re: How to add an ODBC data source during setup?
Too bad, I don't really (want to) know much about Crystal Reports.
You might want to take a look at the RegisterDatabase method in DAO. It allows you to programmatically create the DSN information.
-
November 3rd, 1999, 10:30 AM
#7
Re: How to add an ODBC data source during setup?
Thank you very much! That is what I need!
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
|