Archived

This topic is now archived and is closed to further replies.

Acquiring HWND's from Dialogs

This topic is 4988 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Hello everybody, I''m a little new to windows programming, so I was wondering if you could help me out. When I create a dialog in VC++ that get''s stored in the resource file, everything''s all well and good, all the controls appear and runtime and that. My problem is I can''t modify those controls on the basis I don''t have their HWND. Is there anyway to get it just by using Function(MAKEINTRESOURCE(IDB_BUTTON))? Any help would be much appreciated

Share this post


Link to post
Share on other sites
HWND GetDlgItem(HWND hDlg, int nIDDlgItem);

Pass it the HWND of your dialog, and the resource ID of the control, and it returns the HWND of that control.

Share this post


Link to post
Share on other sites