LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

user32.dll hex/string

Solved!
Go to solution

Hello Everyone,

 

This is more a general question about the SendMessageA() function of the user32.dll 

 

Usually, when I download a VI which utilizes user32.dll, the message being sent is in hex.  The MSDN library, however, lists possible options as descriptive string commands. http://msdn.microsoft.com/en-us/library/windows/desktop/ms644927(v=vs.85).aspx#system_defined 

 

Does anyone know of a resource which connects these two?  Basically, when I see a hex message in labview, I want to determine what command it is so I can understand the functionallity better.  I feel converting random messages from the library into hex is a very poor way to go about this problem.

 

I feel this should be obvious but I'm just not seing it and i haven't found anything in the forums or google searches.

0 Kudos
Message 1 of 4
(3,044 Views)
Solution
Accepted by topic author pjr1121

Microsoft themselves defines the messages in hex so for easier pairing of the messages to the command in question most pprogrammers also use hex.

 

<quote from your link>

Message-identifier values are used as follows:

  • The system reserves message-identifier values in the range 0x0000 through 0x03FF (the value of WM_USER  – 1) for system-defined messages. Applications cannot use these values for private messages.
  • Values in the range 0x0400 (the value of WM_USER) through 0x7FFF are available for message identifiers for private window classes.
  • If your application is marked version 4.0, you can use message-identifier values in the range 0x8000 (WM_APP) through 0xBFFF for private messages.
  • The system returns a message identifier in the range 0xC000 through 0xFFFF when an application calls theRegisterWindowMessage function to register a message. The message identifier returned by this function is guaranteed to be unique throughout the system. Use of this function prevents conflicts that can arise if other applications use the same message identifier for different purposes.

<end quote>

 

There are plenty of external sites which list the value/ message pairs such as:

http://www.autohotkey.com/docs/misc/SendMessageList.htm

0 Kudos
Message 2 of 4
(3,037 Views)

Thank you very much for the link.  My google searches somehow manage to avoid those sites.

0 Kudos
Message 3 of 4
(3,033 Views)

Well the link I posted was just an example (and I think a poor one on retrospect).

I would look for a different list which is more complete.

Perhaps:  http://www.articlegarden.com/Article/What-is-Windows-Message-and-the-List-of-Message-Const-Values/90...

0 Kudos
Message 4 of 4
(3,025 Views)