loForm = NEWOBJECT("form1") loForm.Show(1) RETURN DEFINE CLASS form1 AS form Top = 0 Left = 0 DoCreate = .T. Caption = "Form1" Name = "Form1" ADD OBJECT pageframe1 AS pageframe WITH ; ErasePage = .T., ; PageCount = 2, ; Top = 9, ; Left = 32, ; Width = 327, ; Height = 169, ; Name = "Pageframe1", ; Page1.Caption = "Page1", ; Page1.Name = "Page1", ; Page2.Caption = "Page2", ; Page2.Name = "Page2" function pageframe1.Init() this.page1.AddObject('text1', 'textbox') this.page1.AddObject('text2', 'textbox') this.page1.AddObject('text3', 'textbox') with this.page1.text1 .Height = 23 .Left = 21 .Top = 6 .Width = 100 .visible = .t. endwith with this.page1.text2 .Height = 23 .Left = 69 .Top = 48 .Width = 100 .visible = .t. endwith with this.page1.text3 .Height = 23 .Left = 78 .Top = 104 .Width = 100 .visible = .t. endwith endfunc ADD OBJECT shape1 AS shape WITH ; Top = 6, ; Left = 26, ; Height = 178, ; Width = 335, ; BackStyle = 0, ; Name = "Shape1" PROCEDURE shape1.Click this.Visible = .f. Amouseobj(laObject) Messagebox(laObject[1].Name) Messagebox(laObject[2].Name) this.Visible = .t. ENDPROC ENDDEFINE