Jump to content


Check out our Community Blogs

Register and join over 40,000 other developers!


Recent Status Updates

View All Updates

Photo
- - - - -

how can i change ascii code of my keyboard using a c++ program????

ascii

  • Please log in to reply
1 reply to this topic

#1 ryathegr8

ryathegr8

    CC Lurker

  • Just Joined
  • Pip
  • 1 posts

Posted 28 September 2010 - 07:06 AM

i want to write a code in C++ in which when i Press a key...it displays the letter which i have set in my code for dat key.....it means a program that changes the ascii code of a keyboard.....tell me the logic how can i do that??????
  • 0

#2 Momerath

Momerath

    CC Addict

  • Advanced Member
  • PipPipPipPipPip
  • 282 posts
  • Programming Language:C, Java, C++, C#, PHP, (Visual) Basic, Python, JavaScript, Perl, Visual Basic .NET, Pascal, Ada, Assembly, Fortran, Scheme
  • Learning:Others

Posted 28 September 2010 - 12:15 PM

You can't change the code that the keyboard sends (for most keyboards). You can, on the other hand, intercept the keypress and translate it into something else.

So the logic of it is:
Create a keypress handler.
Attach handler to keypress event

If you wanted more help, I'd ask in the C and C++ forum, as this is the C# forum.
  • 0





Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download