?
Solved

String to WM_Message

Posted on 2006-07-22
4
Medium Priority
?
496 Views
Last Modified: 2010-04-05
Function Translate(Wm_Call: Longint): Boolean;
Begin
 Form1.Edit2.text:=IntToStr(Wm_Call);
 Form1.Edit3.Text:=IntTOHex(Wm_Call,2);
End;


Results

Translate(WM_PAINT);
[15     ]
[0F     ]


Translate(WM_CLOSE);
[16     ]
[10     ]


Easy, now let's suppose i wanted to do the same thing from external user input..

Translate(EditBox1.Text);  //wm_close


Errrrrrooooorrrrrrrrrrrrrrr.....


IS there anyway of doing a reverse lookup on an API call? without building a complete library of their values yourself?

0
Comment
Question by:tobjectpascal
[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
4 Comments
 
LVL 14

Expert Comment

by:Hamidreza Vakilian
ID: 17159775
Hi!

I think it's not available under delphi, because wm_messages are constant values and for example whenever the compiler see wm_close, puts hexadecimal 10 in place of that... It doesn't know wm_close !!!

HRV
0
 
LVL 4

Author Comment

by:tobjectpascal
ID: 17163992
any mods reading this thread...

http://wiki.winehq.org/List_Of_Windows_Messages


I ended up writing a program to extract them for a look up system...

problem solved thanks anyway guys, i thought it was not possible to do this, but it would be great if it could....
0
 
LVL 1

Accepted Solution

by:
Computer101 earned 0 total points
ID: 17983758
PAQed with points refunded (125)

Computer101
EE Admin
0

Featured Post

Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

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

The uses clause is one of those things that just tends to grow and grow. Most of the time this is in the main form, as it's from this form that all others are called. If you have a big application (including many forms), the uses clause in the in…
In my programming career I have only very rarely run into situations where operator overloading would be of any use in my work.  Normally those situations involved math with either overly large numbers (hundreds of thousands of digits or accuracy re…
In this video we outline the Physical Segments view of NetCrunch network monitor. By following this brief how-to video, you will be able to learn how NetCrunch visualizes your network, how granular is the information collected, as well as where to f…
This is my first video review of Microsoft Bookings, I will be doing a part two with a bit more information, but wanted to get this out to you folks.
Suggested Courses
Course of the Month15 days, 10 hours left to enroll

741 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