How do you programmatically change the tab order in a Win32 dialog?

前端 未结 2 592
梦如初夏
梦如初夏 2020-12-11 01:59

Often time I need to add a control to a dialog after the dialog has been generated via dialog template and CreateDialogIndirect. In these cases the tab order is set by the

2条回答
  •  再見小時候
    2020-12-11 02:52

    I know this is an old question but here is how to do it at compile time (which is preferable in the vast majority of cases): http://msdn.microsoft.com/en-us/library/7039hzb0(v=vs.80).aspx

    My favourite method:

    1. From the View menu, choose Tab Order.
    2. Choose Assign Interactively.
    3. Double-click the tab order box beside the control you want to be the first control in the tab order.
    4. Click the tab order box for each of the other controls.
    5. Click anywhere on the form to save your changes and exit Tab Order mode, or press ESC to exit Tab Order mode without saving your changes.

提交回复
热议问题