PDA

View Full Version : set defualt button for radio button group



megheim
05-24-2004, 06:15 PM
Using dev studio install script. i've got a custom dialog with two radio buttons in a button group, where they should be exclusive of each other. how do a set one button selected as a default when the dialog is first displayed?

thanks!

Mark at IS
05-25-2004, 08:03 AM
Call CtrlSetState, as in the following sample code snippet:
nCmdValue = WaitOnDialog("MYCOMDIALOG");
switch (nCmdValue)
case DLG_INIT:
CtrlSetState("MYCOMDIALOG", ID_TONE, BUTTON_CHECKED);

megheim
05-25-2004, 09:58 AM
oops. i was just missing the DLG_INIT. thank you.