Cheat Engine Forum Index Cheat Engine
The Official Site of Cheat Engine
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 


[c++] Help using checkboxes and radioboxes

 
Post new topic   Reply to topic    Cheat Engine Forum Index -> General programming
View previous topic :: View next topic  
Author Message
iRiot
Master Cheater
Reputation: 0

Joined: 03 Jul 2007
Posts: 395
Location: Aka RIOT

PostPosted: Fri Nov 14, 2008 10:25 pm    Post subject: [c++] Help using checkboxes and radioboxes Reply with quote

I need some help using checkboxes and radioboxes in c++ iam using a resource file and i was wondering how would i start my code like ... if checkbox checked = true then being w/e how should i start out? and the case? what should i part it under example: case
Code:
WM_INITDIALOG:
?
_________________
Back to top
View user's profile Send private message
lurc
Grandmaster Cheater Supreme
Reputation: 2

Joined: 13 Nov 2006
Posts: 1900

PostPosted: Fri Nov 14, 2008 10:34 pm    Post subject: Reply with quote

Filter through WM_COMMAND, and use IsDlgButtonChecked (or send the message BM_GETCHECK explicitly.)

Code:
LRESULT CALLBACK WndProc(HWND hWnd, UINT uMsg, WPARAM wParam, LPARAM lParam)
{
    switch (uMsg)
    {
    case WM_COMMAND:
        switch (LOWORD(wParam))
        {
            case IDC_CHECKBOX:
                if (IsDlgButtonChecked(hWnd, IDC_CHECKBOX))
                     // Checked... Add instructions.
                else
                     // Unchecked... ADd instructions.
                // You could also check for a ret of 2 (Intermediate check)
                break;
        }
        break;
    // All the other messages... ret DefWindowProc on defualt.
    }
    return 0;
}

_________________
Back to top
View user's profile Send private message
iRiot
Master Cheater
Reputation: 0

Joined: 03 Jul 2007
Posts: 395
Location: Aka RIOT

PostPosted: Fri Nov 14, 2008 10:36 pm    Post subject: Reply with quote

thanks lurc
_________________
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    Cheat Engine Forum Index -> General programming All times are GMT - 6 Hours
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 cannot attach files in this forum
You can download files in this forum


Powered by phpBB © 2001, 2005 phpBB Group

CE Wiki   IRC (#CEF)   Twitter
Third party websites