Re: How to find those constants for a API Declare
- From: "Bill Plenge" <B_Plenge@xxxxxxxxxx>
- Date: Wed, 21 Mar 2007 20:50:30 -0500
simon wrote:
Hello all friends. I am a VB-API beginner. I want to know hoe to find
its constants for a API Declare. For example:
When we declare a function:
Private Declare Function RegCreateKey Lib "advapi32.dll" Alias
"RegCreateKeyA" (ByVal hKey As Long, ByVal lpSubKey As String,
phkResult As Long) As Long
Const ERROR_SUCCESS = 0&
Const ERROR_BADDB = 1009&
Const ERROR_BADKEY = 1010&
Const ERROR_CANTOPEN = 1011&
Const ERROR_CANTREAD = 1012&
Const ERROR_CANTWRITE = 1013&
Const ERROR_REGISTRY_RECOVERED = 1014&
Const ERROR_REGISTRY_CORRUPT = 1015&
Const ERROR_REGISTRY_IO_FAILED = 1016&
Const HKEY_CLASSES_ROOT = &H80000000
Const HKEY_CURRENT_USER = &H80000001
Const HKEY_LOCAL_MACHINE = &H80000002
The questions are:
1. Why we just make those constants in the code?
2. What is relevance with those constants and this API function?
3. How can I find which constants will be used in a API function?
4. I´ve heard that in the C++ head file (.h file) can be found this
relation, but I don´t know hoe to find it yet.
5. Do you have any tools to refer it? The VB API viewer can find those
Declares, but I can´t find each API will use which constants.
Waiting you answer.thank you!!
Best Regards.
Simon
Best tool I know of for finding which API uses what constants/parameters is
the API Guide available from http://www.allapi.net/
Hope this helps.
Best,
Bill
.
- Follow-Ups:
- Re: How to find those constants for a API Declare
- From: Steve Gerrard
- Re: How to find those constants for a API Declare
- References:
- How to find those constants for a API Declare
- From: simon
- How to find those constants for a API Declare
- Prev by Date: How to find those constants for a API Declare
- Next by Date: Re: How to find those constants for a API Declare
- Previous by thread: How to find those constants for a API Declare
- Next by thread: Re: How to find those constants for a API Declare
- Index(es):
Relevant Pages
|