Question about taborder using win32 API
-
Hi all, I am trying to build my own C++ framework around the win32 API. The purpose of doing this is to learn how things work behind the (sometimes) mysterious scenes of MFC. My question is the following: When painting a dialog in VC, you can specify that a control has the WS_TABSTOP style. If you do that, you can also specify the taborder in which the focus will traverse when using the TAB key. In my framework, controls are also created using WS_TABSTOP. Firstly, in my framework, it seems the tab key has absolutely no effect whatsoever. Is the taborder functionality programmed in MFC somewhere? I couldn't find it, but maybe I am not looking close enough. Secondly, how can I specify the order in which the focus will traverse? It seems not related to the ID value of the control. Thirdly, if someone is interested in the code I am using related to answering this question, let me know. Best regards, Perry
-
Hi all, I am trying to build my own C++ framework around the win32 API. The purpose of doing this is to learn how things work behind the (sometimes) mysterious scenes of MFC. My question is the following: When painting a dialog in VC, you can specify that a control has the WS_TABSTOP style. If you do that, you can also specify the taborder in which the focus will traverse when using the TAB key. In my framework, controls are also created using WS_TABSTOP. Firstly, in my framework, it seems the tab key has absolutely no effect whatsoever. Is the taborder functionality programmed in MFC somewhere? I couldn't find it, but maybe I am not looking close enough. Secondly, how can I specify the order in which the focus will traverse? It seems not related to the ID value of the control. Thirdly, if someone is interested in the code I am using related to answering this question, let me know. Best regards, Perry
All these functions are exported from Shlwapi.dll (7/24/2002) as (ASCII: StrRetToBufA, UNICODE: StrRetToBufW etc) If not included in your version of Shlwapi.h you could consider checking in the latest W32 SDK (note that the standard MSDevStudio files are usually quite out of date). Quick solution might be to add its declaration yourself in your code. You would need of course to make sure that the right version of Shlwapi.dll is installed on the target system
-
Hi all, I am trying to build my own C++ framework around the win32 API. The purpose of doing this is to learn how things work behind the (sometimes) mysterious scenes of MFC. My question is the following: When painting a dialog in VC, you can specify that a control has the WS_TABSTOP style. If you do that, you can also specify the taborder in which the focus will traverse when using the TAB key. In my framework, controls are also created using WS_TABSTOP. Firstly, in my framework, it seems the tab key has absolutely no effect whatsoever. Is the taborder functionality programmed in MFC somewhere? I couldn't find it, but maybe I am not looking close enough. Secondly, how can I specify the order in which the focus will traverse? It seems not related to the ID value of the control. Thirdly, if someone is interested in the code I am using related to answering this question, let me know. Best regards, Perry
Perry Bruins wrote: it seems the tab key has absolutely no effect whatsoever. You need to call
IsDialogMessage()
in your message loop for the standard keyboard navigation to work. Perry Bruins wrote: Secondly, how can I specify the order in which the focus will traverse? Tab order is the same as the Z-order of the controls. UseSetWindowPos()
to change the Z-order. --Mike-- Ericahist | CP SearchBar v2.0.2 | Homepage | RightClick-Encrypt | 1ClickPicGrabber "That probably would've sounded more commanding if I wasn't wearing my yummy sushi pajamas." -- Buffy