Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
SQLConfigDataSource problem
Message
Information générale
Forum:
Visual FoxPro
Catégorie:
Fonctions Windows API
Divers
Thread ID:
00111019
Message ID:
00111344
Vues:
35
>Hi Mark,
>
>Cool! I need to do this myself. What's lnInt1 for? I don't see it referenced anywhere else.
>
>Also, if you don't mind, could you post the code that checks for the existence of a DNS registry entry?

Sorry, the lnInt1 should have been removed. I had been using that as the first parameter in the SQLConfigDataSource() function.

The code I use to check the Win95 registry is in the Files section of the UT under Classes/VCX, Registry.zip. This file was uploaded by Rick Strahl of West Wind Technologies.

I set up the following in my application to use the registry.prg functions:
#Include registry.h
set procedure to registry
oRegistry=CREATE("Registry")
DIMENSION taVals[1,2]
lcRegSubKey = "SOFTWARE\ODBC\ODBCINST.INI\Microsoft ODBC for Oracle"
lcRegHKey = HKEY_LOCAL_MACHINE
lnVals=oRegistry.GetEnumValues(@taVals, lcRegHKey, lcRegSubKey)

I modified Rick's code to take out the example code. I left all the constant definitions in the registry.prg.

The lcRegSubKey and lcRegHKey is where the ODBC DSN information can be found in the Win95 registry if you browse it with Regedit.exe utility.
Mark McCasland
Midlothian, TX USA
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform