Want to win a PS4? Go Premium and enter to win our High-Tech Treats giveaway. Enter to Win

x
?
Solved

intercept the wm_char message

Posted on 2003-10-22
10
Medium Priority
?
628 Views
Last Modified: 2013-12-03
i have to hook the keyboard and get keydown event and which key is pressed and then
intercept the wm_char message which is generated for that keydown event and change that particular character and translate that to my own character and that character is an extended ascii character.
Sir i have designed a font file and i included lot of new characters in the font file to accomadate more characters which Tamil language have.I can easily manage to access the 52 characeters in A_Z and a-z using normal keyboard ,but i have included 200 characters .I am not using unicode for i am not using opentype font but only true type font.the remaining characters are in other ascii range .Is it possibe to display them by changing the wm_char message.?
if so how is it possible ?
Do anybody know how to hook the message and intercept keyboard messages and change the character system wide.

thanks in advance
0
Comment
Question by:vimalpercy
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
10 Comments
 
LVL 9

Expert Comment

by:bhagyesht
ID: 9597374
which language are you developing in? if ist only for your application then why hooks? just check the keystrokes for that window and alter them
0
 
LVL 9

Expert Comment

by:bhagyesht
ID: 9597378
Generally speaking programming hook is installing special function to be called when certain event occured. Hooks are especially usefull for "spying" or changing different sytem event you don't have full access to. For instance Spy program shipped with VC++. it sets up hook for spying all messages for all windows from all processes and threads. It doesn't have access to all these windows but it can hoks and displays all messages sent to these windows. For instance in my application I forced to the problem how to make standard message box top most. Since this window is created insed user system modal the only one way is to setup a hook and modify message box style when hook procedure is called. There are several hooks. To set up window hook use SetWindowHookEx Win32 API function
0
 
LVL 48

Expert Comment

by:AlexFM
ID: 9598124
0
Concerto Cloud for Software Providers & ISVs

Can Concerto Cloud Services help you focus on evolving your application offerings, while delivering the best cloud experience to your customers? From DevOps to revenue models and customer support, the answer is yes!

Learn how Concerto can help you.

 

Author Comment

by:vimalpercy
ID: 9625071
Thank you very much for your reply
Sir i need little detailed answers and how to implement practically with if possible with an example.

1. How to intercept that message which is generated for a keydown event , before it goes to the respective application or any application , from my application.
2.how to obtain wm_char message from that intercepted message.
4.How to prevent that message from going to its defalut application.
3.How to change the wm_char message and load my own exteded ascii wm_char message ?
4 how to send to the active application or to the application that message to be send ?

Sir I want answers in the form of 1,2,3 & 4 for each question and if possible elobrate answers for me to apply that codings in my aplication.

Thanks in advance
0
 

Author Comment

by:vimalpercy
ID: 9728300
Hello Sir
    I have implemented Wm_getmessage hook and got wm_char message
Say Wm_char = A  
Now what i want to do is to Allow this character to go the application but i have to translate the character to Extended ascii character Say €
LRESULT CALLBACK GetMsgProc(int nCode, WPARAM wParam, LPARAM lParam)
{
   if(nCode < 0)
   {      
     CallNextHookEx(hMsghook, nCode, wParam, lParam);
    return 0;
   }
          LPMSG lpMsg = (LPMSG) lParam;

              if(lpMsg->message == WM_CHAR )
                 (((((((

                                 Here i need the codings to
                                 1. Change the Wm_char to extended ascii character
                                 2.i want the codings how to send a character or combined character to the active application.
     
   return CallNextHookEx(hMsghook, nCode, wParam, lParam);
}
0
 

Author Comment

by:vimalpercy
ID: 10318967
I like to delete the question for nobody answered the question.
0
 
LVL 9

Expert Comment

by:bhagyesht
ID: 10319701
PAQ/refund
Bhagyesh Trivedi
0
 

Accepted Solution

by:
PashaMod earned 0 total points
ID: 11023243
PAQed, with points refunded (500)

PashaMod
Community Support Moderator
0

Featured Post

VIDEO: THE CONCERTO CLOUD FOR HEALTHCARE

Modern healthcare requires a modern cloud. View this brief video to understand how the Concerto Cloud for Healthcare can help your organization.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

In this post we will learn how to make Android Gesture Tutorial and give different functionality whenever a user Touch or Scroll android screen.
The SignAloud Glove is capable of translating American Sign Language signs into text and audio.
An introduction to basic programming syntax in Java by creating a simple program. Viewers can follow the tutorial as they create their first class in Java. Definitions and explanations about each element are given to help prepare viewers for future …
Starting up a Project

618 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question