The MASM Forum
Welcome,
Guest
. Please
login
or
register
.
Did you miss your
activation email
?
1 Hour
1 Day
1 Week
1 Month
Forever
Login with username, password and session length
News:
MASM32 Downloads
Home
Help
Search
Login
Register
The MASM Forum
»
Projects
»
Easy Code IDE 32/64-bit
(Moderator:
rsala
) »
Enabling/Disabling controls during run time
« previous
next »
Print
Pages: [
1
]
Author
Topic: Enabling/Disabling controls during run time (Read 4859 times)
K_F
Member
Posts: 1731
Anybody out there?
Enabling/Disabling controls during run time
«
on:
March 20, 2013, 06:19:47 PM »
Hi Ramon
Playing with a combo box, but cannot see where to enable or disable it. There is no specific API for this so I'd imagine I'd have to set the enable property on the window handle.
Would this be the case, and is this handle the one you get from the GetWindowHandle proc ?
Thanks
Logged
'Sire, Sire!... the peasants are
Revolting
!!!'
'
Yes, they are.. aren't they....
'
ragdog
Member
Posts: 609
Re: Enabling/Disabling controls during run time
«
Reply #1 on:
March 20, 2013, 07:26:29 PM »
Code:
[Select]
invoke GetDlgItem,hWnd,IDC_CONTROL_ID
invoke EnableWindow,eax,FALSE
FALSE =Disable
TRUE = Enable
Logged
rsala
Moderator
Member
Posts: 354
Re: Enabling/Disabling controls during run time
«
Reply #2 on:
March 21, 2013, 06:03:50 AM »
Hi K_F,
As radgog said, you have to use the
EnableWindow
API function. You can get the handle with the
GetWindowItem
EC method or with the
GetDlgItem
API function.
Logged
EC coder
K_F
Member
Posts: 1731
Anybody out there?
Re: Enabling/Disabling controls during run time
«
Reply #3 on:
March 22, 2013, 08:48:00 AM »
Thanks guys..
Logged
'Sire, Sire!... the peasants are
Revolting
!!!'
'
Yes, they are.. aren't they....
'
Print
Pages: [
1
]
« previous
next »
The MASM Forum
»
Projects
»
Easy Code IDE 32/64-bit
(Moderator:
rsala
) »
Enabling/Disabling controls during run time