PUBLIC oform1 oform1=NEWOBJECT("form1") oform1.Show RETURN DEFINE CLASS form1 AS form autocenter = .T. Caption = "Toolbar focus" Name = "Form1" ADD OBJECT command1 AS commandbutton WITH ; Top = 28, ; Left = 64, ; Height = 27, ; Width = 84, ; Caption = "OPEN", ; Name = "Command1" ADD OBJECT command2 AS commandbutton WITH ; Top = 76, ; Left = 96, ; Height = 27, ; Width = 84, ; Caption = "GO", ; Enabled = .F., ; Name = "Command2" PROCEDURE command1.Click this.Enabled = .F. =ADDPROPERTY(m.thisform,"tb_fonts",CREATEOBJECT("tbarFonts")) thisform.command2.Enabled = .t. ENDPROC PROCEDURE command2.Click thisform.tb_fonts.TextBox1.SetFocus ENDPROC ENDDEFINE DEFINE CLASS tbarFonts AS Toolbar ADD OBJECT TextBox1 AS TextBox ADD OBJECT TextBox2 AS TextBox PROCEDURE Init this.Dock(0) this.Visible = .T. ENDDEFINE