Hi all, I'm trying to get the characters in a label or write to
one but I have no idea how to do it, I thought of using it
FindWindow> FindWindowEx> sendMessage
this is how you do it?
by the way anyone knows a little tutorial on working with controls?
thanks :bg
When you create any control with CreateWindowEx, it returns a handle to the created control, save that value. If a control is created in a resource, then you can get the handle of the control in the parents WindowProc, usually in WM_INITDIALOG and do:\
invoke GetDlgItem, hDlg, CTLID where CTLID is the number you assigned the control in the resource file.
Now to set the text, you send controls messages
invoke SendMessage, HandleToControl, WM_SETTEXT, 0, offset szStringToDisplay
To get the text of a control
invoke SendMessage, HandleToControl, WM_GETTEXT, SIZEOFBUFFER, AddressOfBufferToGetString
The are not called labels, they are called static controls :bg
:clap: :dance: Thanks Gunner, I am making a small app ( my first app) that I think public in the forum :)