![]() |
F1 - Printable Version +- Mirage Source (https://mirage-engine.uk/forums) +-- Forum: Mirage Source (Nostalgia) (https://mirage-engine.uk/forums/forumdisplay.php?fid=61) +--- Forum: Archive (2006-2011) (https://mirage-engine.uk/forums/forumdisplay.php?fid=18) +---- Forum: General (https://mirage-engine.uk/forums/forumdisplay.php?fid=17) +---- Thread: F1 (/showthread.php?tid=842) |
F1 - Braydok - 22-03-2007 How do you register is someone has pressed F1? - Tony - 22-03-2007 What do you mean? Open the new account window? - Spodi - 22-03-2007 GetAsynceKeyState(vbKeyF1)? - Spodi - 22-03-2007 With my method, you will get it if the key is pressed even if the window doesn't have the focus (ie they're doing something in the background). You also have to use some form of timer to constantly check for the event since it is not event-driven like KeyUp/KeyDown subs. With Verrigan's method, you have to have focus on the correct object, and only one object can receive the KeyUp/KeyDown/KeyPress event. This means if they click a form and press buttons, it won't register under Form_KeyDown. Pain in the butt either way. :wink: - Braydok - 22-03-2007 Well, I'm just aiming to create a admin panel like PlayerWorlds's. So I just need to be able to check if someone has puched the f1 key, and if so then make visible the panels that they can see. - Robin - 22-03-2007 http://www.animerealm.co.uk/uploads/tutorials/Temporary_Archive/Admin%20Panel%20Tut.html - Braydok - 26-03-2007 Oh, thnaks, this'll help alot. ![]() ~Braydok |