wartiaga wrote:nageswaragunupudi wrote:
- Code: Select all Expand view
? oBtn:WinStyle( WS_TABSTOP ) --> lActive
oBtn:WinStyle( WS_TABSTOP, .T. (or) .F. ) // Enable/Disable the TabStop style
Mr. Nages
Desn't work. In the TABSTOP option of the button in Pelles c I set it to YES but when I use oBtn:WinStyle( WS_TABSTOP, .F. ) it it still continues obeying the initial TABSTOP.
Thank you!
No.
This should work and in fact this works.
Keep this in ON INIT clause.
In the above example, according to the RC file, tabstop for oBtn[ 2 ] is inactive and tabstop for oBtn[ 1 ] and oBtn[ 2 ] are active.
Please try this program. Here we enable tabstop for the second button and disable tabstop for the 3rd button.
- Code: Select all Expand view
- #include "FiveWin.ch"
Function Main()
LOCAL oDlg, oBtn[3]
DEFINE DIALOG oDlg RESOURCE "TEST"
REDEFINE BUTTONBMP oBtn[1] PROMPT "&One" ID 201 OF oDlg ACTION MsgInfo("One")
REDEFINE BUTTONBMP oBtn[2] PROMPT "&Two" ID 202 OF oDlg ACTION MsgInfo("Two - Without TabStop")
REDEFINE BUTTONBMP oBtn[3] PROMPT "&Three" ID 203 OF oDlg ACTION MsgInfo("Three")
oDlg:bInit := { || oBtn[2]:WinStyle( WS_TABSTOP, .T. ), oBtn[3]:WinStyle( WS_TABSTOP, .F. ) }
ACTIVATE DIALOG oDlg CENTERED
RETURN NIL