PUBLIC oTestForm oTestForm=NEWOBJECT("TestForm") oTestForm.Show RETURN ************************************************** *-- Form: TestForm (e:\temp\testprog.scx) *-- ParentClass: form *-- BaseClass: form *-- Time Stamp: 01/19/00 10:58:09 PM * * DEFINE CLASS TestForm AS form DoCreate = .T. Name = "TestForm" ADD OBJECT commandbutton1 AS commandbutton WITH ; Top = 95, ; Left = 125, ; Name = "commandbutton1" PROCEDURE showprogram acti screen ? 'Program(): ' + program() ? 'Program(-1): ' + tran(program(-1)) FOR i = 0 to program(-1) ? 'Program(' + tran(i) + '): ' + program(i) ENDFOR &&* i = 1 to program(-1) ENDPROC PROCEDURE commandbutton1.Click thisform.ShowProgram() ENDPROC ENDDEFINE * *-- EndDefine: TestForm **************************************************Cheers,