Contribute  :  Web Resources  :  Past Polls  :  Site Statistics  :  Downloads  :  Forum  
    BiW ReversingThe challenge is yours    
 Welcome to BiW Reversing
 Monday, June 18 2018 @ 05:49 AM CEST
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

SendDlgItemMessage

 
Post new topic   Reply to topic    www.reversing.be Forum Index -> Coding Corner
View previous topic :: View next topic  
Author Message
sharpe
Frequent poster
Frequent poster


Joined: 20 Mar 2005
Posts: 65

PostPosted: Thu Mar 22, 2007 1:24 pm    Post subject: SendDlgItemMessage Reply with quote

I am having troubles enabling buttons with the SendDlgItemMessage function. I have a button called IDC_BUTTON and am trying this:

SendDlgItemMessage,hWnd,IDC_BUTTON,WM_ENABLE,1,0

This doesn't work with buttons. I am able to use it fine with text fields.

Does anyone have any ideas?

Thanks in advance.
Back to top
View user's profile Send private message Visit poster's website
Knight
Regular
Regular


Joined: 21 Aug 2005
Posts: 122

PostPosted: Thu Mar 22, 2007 6:25 pm    Post subject: Reply with quote

There's function EnableWindow for that purpose...

Regards,
Knight
Back to top
View user's profile Send private message
sharpe
Frequent poster
Frequent poster


Joined: 20 Mar 2005
Posts: 65

PostPosted: Thu Mar 22, 2007 7:59 pm    Post subject: Reply with quote

Hi there,

I tried EnableWindow but was unable to get it to work. I read on Hutch's (masm32) site about this method but can't get it to work with buttons. Do you have an example?

Thanks in advance.
Back to top
View user's profile Send private message Visit poster's website
Knight
Regular
Regular


Joined: 21 Aug 2005
Posts: 122

PostPosted: Fri Mar 23, 2007 10:24 am    Post subject: Reply with quote

This should work:
Code:
invoke GetDlgItem,hWnd,IDC_BUTTON
invoke EnableWindow,eax,0

Regards,
Knight
Back to top
View user's profile Send private message
sharpe
Frequent poster
Frequent poster


Joined: 20 Mar 2005
Posts: 65

PostPosted: Fri Mar 23, 2007 8:05 pm    Post subject: Reply with quote

Nice one, works perfectly.
Thanks very much Surprised
Back to top
View user's profile Send private message Visit poster's website
Display posts from previous:   
Post new topic   Reply to topic    www.reversing.be Forum Index -> Coding Corner All times are GMT + 1 Hour
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You can attach files in this forum
You can download files in this forum


Powered by phpBB © 2001, 2005 phpBB Group
 Copyright © 2018 BiW Reversing
 All trademarks and copyrights on this page are owned by their respective owners.
Powered By Geeklog 
Created this page in 0.05 seconds