Where do I get a list of the messages I can send with SENDMESSAGE? For instance, if I want to send a message to a richtext control telling it to scroll its contents to the top, where do I find out what messages apply to this effort? MSDN SENDMESSAGE topic was useless. I have to read a lib file or a header or somesuch bit-level source, right? ???
(It's quite frustrating to know exactly what I want to have happen, and then run into an endless stream of obstacles in cobbling together the implementation.)
Okay, so there's stuff in "windows.inc". Don't know what it means, or how to use it, but it seems to be there.
Look for the control you are dealing with to see what messages it will respond to.
All the commands that you send to the richedit control like getfirstline or rtsave, etc are all actually sent to the richedit control via SENDMESSAGE.
Paul took care of a lot of them by hard coding them into the CONTROLCMD but it doesn't mean he hard coded all possibilities.
even the window and dialog message handlers that you use all the time are based upon the SENDMESSAGE function.
Larry
Thanks, Larry. I'm getting it, slowly but erratically. A little trial, a lot of error, and we're on our way!
Sometimes it's the "blind leading the blind"
I'm learning this stuff right now also.
The main reason I don't expound on some of my answers is because I've typed absolutely all I know about the subject to begin with.
Larry
MSDN has individual control information, which among other things has the list of messages each control responds to.
This one is for the RE control:
http://msdn2.microsoft.com/en-us/library/bb787605(VS.85).aspx
There is no "all inclusive" list of messages as it would number in the 10's of thousands if you totalled all of the messages for every control and window class in existance. That is not including user defined messages.
Paul.
Thanks, Paul.
Tens of thousands, hey? I'd better get started, then... ;D
And the first thing I see in the Rich Edit list is "EM_AUTOURLDETECT Message". This is interesting, because I'm doing a lot of that in my project.
The things you learn, just by asking!
And now CFE_LINK and CFM_LINK in CHARFORMAT2.... Cover me, I'm going in! ::)