Hi Edgar,
If you look at the help for the GetUserEvent() function, you'll see it says:
"Obtains the next commit event or programmer-defined event from the GetUserEvent queue."
That means you won't be getting any events, since there are no
COMMIT_EVENTs generated for the text message, and you are not using
QueueUserEvent() to add any of your own events to the queue.
Using a control callback is really the only obvious way to get the left
click event on a text control. If you are dead set against using
a callback, you can try to fake a text message using other controls
that fire commit events. For example, you can use a Command
Button and just make the button color transparent. This will
generate a commit event that will be detected by GetUserEvent() when
clicked, but it will look like a text message. However, you may
not like the fact that the label gets a box around it when the button
gets the focus. If that is a problem, you can use a Picture
Button. Again, make the button color transparent, delete the
label, and for the picture, just create a text message with the text
you want to display, copy it, then in the Edit Picture Button dialog,
click the "Image..." button, and select "Paste Image". Now the
only real visible difference between this and a real text message is
that when clicked, you'll see the text shift a little bit, since it is
actually a button being pressed. Also, if the control is resized at
run-time, the text will look pixelated, since it is a bitmap.
I hope this helps you get things looking/working the way you want.
Mert A.
National Instruments