i am new to c++ so please dont throw any crazy words around :D
im using dev C++ form bloodshed as my editor / compiler
what i am trying to do is when a user hits one of the special buttons all keyboard input after that will be reformated depending
on which button he has click im just not sure where to go from here there's what i have so far
#include <iostream>
#include <windows.h>
using namespace std;
int dostuff (int key_stroke);
//===============================================================================================================================
int main(void)
{
char i;
while (1) { for(i = 8; i <= 190; i++) if (GetAsyncKeyState(i) == -32767){dostuff (i); }}
cin.get( ); //make system hold
return 0;
}
//===============================================================================================================================
int dostuff (int key_stroke)
{
if (key_stroke == 45){cout << "i do stuff 4 a_";}// insert button on keyboard
if (key_stroke == 36){cout << "i do stuff 4 b_";}// home button on keyboard
if (key_stroke == 33){cout << "i do stuff 4 c_";}// page up button on keyboard
cout << key_stroke << endl; // just echo what button is pressed
}