Archive: Set Focus on title and subtitle


Set Focus on title and subtitle
I tried searching the wiki for this and only found a function that can set focus on a custom page control. However, what I'm trying to do is set the focus on the installer's top title and subtitle. My guess is it can be done using the System plugin but I don't know how to do it. Can anyone help ?


I don't think a label control can grab focus anyway?


Originally posted by iceman_k
I don't think a label control can grab focus anyway?
sure it can

That's not what Microsoft says:

Although static controls are child windows, they cannot be selected. Therefore, they cannot receive the keyboard focus and cannot have a keyboard interface.

:| could there be a difference between keyfocus and mousefocus ? because if 2 simple lines in VB can do it, I doubt it can't be done. I'm not trying to select it by having the user press the "Tab" button. I just want to set focus on it so that it appears OVER a control which is placed above it by default. Anyway, it's not that important so I might as well drop this topic.


Then you want to change the Z-order not focus.
You can call SetWindowPos to do this with the System plugin.

-Stu


Well here's what I was able to find it...
System::Call "${sysSetWindowPos} (parameters)"

and as I saw on msdn, I probably need to use HWND_TOP or HWND_TOPMOST as the second paramter... However, I don't know how to obtain the control id or how the rest of the paramters should be. Can you assist me with that please ?


What control is being created over the page title/subtitle?
This should not happen.
Anyway, the best way for you to find the control handles will be to look at the Modern UI macro MUI_HEADER_TEXT which sets the values of the title and subtitle.


it's actually the header image, because I added NO_RESIZE and the title/subtitle appear above the image just fine for all pages except the first one.