- 28 Aug. 2008 - 21:05:
How to determine which control number runs which action?
Perhaps the best way to ask this question is through an example. The controls for the "Run" dialog (shell32.dll
, dialog 1003) are:
" CONTROL 160, 12297, STATIC, SS_ICON | WS_CHILD | WS_VISIBLE, 7, 11, 18, 20
CONTROL "Type the name of a program, folder, document, or Internet resource, and Windows will open it for you.", 12289, STATIC, SS_LEFT | WS_CHILD | WS_VISIBLE | WS_GROUP, 36, 11, 182, 18
CONTROL "&Open:", 12305, STATIC, SS_LEFT | WS_CHILD | WS_VISIBLE | WS_GROUP, 7, 39, 24, 10
CONTROL "", 12298, COMBOBOX, CBS_DROPDOWN | CBS_AUTOHSCROLL | CBS_DISABLENOSCROLL | WS_CHILD | WS_VISIBLE | WS_VSCROLL | WS_TABSTOP, 36, 37, 183, 200
CONTROL "Run in separate &memory space", 12306, BUTTON, BS_AUTOCHECKBOX | WS_CHILD | WS_VISIBLE | WS_DISABLED | WS_TABSTOP, 36, 51, 183, 10
CONTROL "OK", 1, BUTTON, BS_DEFPUSHBUTTON | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 62, 70, 50, 14
CONTROL "Cancel", 2, BUTTON, BS_PUSHBUTTON | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 116, 70, 50, 14
CONTROL "&Browse...", 12288, BUTTON, BS_PUSHBUTTON | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 170, 70, 50, 14 ", the last six of which perform some type of action. I'm assuming that it isn't the text of the action ("&Open:", none, "Run in separate &memory space", "OK", "Cancel" and "&Browse...", but the number following the text (12305, 12298, 12306, 1, 2, and 12288) that determines which action selecting that control will perform. However, I've been unable to figure out how the dialog boxes determine which action matches up with which number. Is the only way to obtain such data is to go through every .exe, .dll, etc. and make a list of them? If so, does anyone here if someone's already done this and made such a list available on the internet? While I would agree that for most actions there probably aren't any practical reasons to add them to any dialog box that doesn't have them, but I think it might be helpful to have an "apply"-like button on the run dialog that would start a program without closing the run dialog if one had several programs one wanted to start at the same time without having to re-open the dialog several times or to have a clock and/or calendar on the start menu and/or logon dialog (without having to search through .exe's, .dll's, etc. to find the required control number every time I wanted to add a control). Or one could switch the "Ok" and "Shutdown" numbers on the logon screen to see how long it takes for others to figure out why the computer seems to keep wanting to shutdown every tiime they try to log on.