PDA

Click to See Complete Forum and Search --> : Making an API declaration in C++ ?


rino_2
Jun 23rd, 2000, 05:22 PM
Hi everybody,

Does anybody know how to make an API declaration in C++ ? If so, could you please give me an example using the GetTickCount API and printing the result using the Cout method. Thanks

parksie
Jun 23rd, 2000, 05:40 PM
in c++, just #include "windows.h" is enough, because that will set up the whole api for you:


#include <iostream>
#include "windows.h"

using namespace std;

void main() {
long lMyNum = GetTickCount(); // use API function
cout << "Count: " << lMyNum << endl;
}

rino_2
Jun 23rd, 2000, 05:45 PM
Thanks a lot Parksie! Wow, thats even easier than in VB!