Thread: C++, blocking keystrokes

  1. #1
    Unregistered
    Guest

    C++, blocking keystrokes

    Hi, I'm looking for a way to block certain keystrokes when the program is open..

    I'd really appreciate a kick in the right direction..

  2. #2
    Registered User
    Join Date
    Feb 2002
    Posts
    589
    What type of key strokes do you want to block?

  3. #3
    Unregistered
    Guest
    well, like stop people pressing the 'k' key or something...

  4. #4
    Registered User
    Join Date
    Feb 2002
    Posts
    589
    You could use a screw driver *smile* I am not sure what you are tring to do. Basicly just design your program so it reacts to specific keystroke and don't reacts to 'k'. If you want your program to stop the user from using 'k' when entering input info you can design a test statment that deletes the k when ever it been entered. you could look into kbhit() in comination with getchar()

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Fake keystrokes to another process
    By Nota in forum Windows Programming
    Replies: 20
    Last Post: 01-26-2009, 11:56 PM
  2. How to initialize a non blocking socket using only winsock library
    By *DEAD* in forum Networking/Device Communication
    Replies: 4
    Last Post: 01-18-2008, 07:03 AM
  3. Sending keystrokes to another view
    By azeemanwer in forum C++ Programming
    Replies: 2
    Last Post: 08-28-2007, 10:41 AM
  4. non blocking recv
    By rohit in forum Linux Programming
    Replies: 4
    Last Post: 03-05-2002, 09:35 PM