Public oForm oForm=Createobject('MyForm') oForm.Show() Function Translate(tcCaption) Return Proper(m.tcCaption)+'BindEventTranslator' Define Class myForm As Form Add Object lbl1 As Label With Left=10,Top=10,AutoSize=.T.,Caption="mylabel1" Add Object lbl2 As Label With Left=10,Top=40,AutoSize=.T.,Caption="mylabel2" Add Object lbl3 As Label With Left=10,Top=70,AutoSize=.T.,Caption="mylabel3" Add Object cmdChangeCaptions As CommandButton ; WITH Left=10,Top=100,AutoSize=.T.,Caption="Change" Procedure Init This.AddProperty("oTranslateTools", Newobject('TranslateTools')) For Each oControl In This.Controls If Lower(oControl.BaseClass) == 'label' Bindevent(oControl, "Caption", This.oTranslateTools, "Translater",1) Endif Endfor Endproc Procedure cmdChangeCaptions.Click With Thisform .lbl1.Caption = 'newlabel1' .lbl2.Caption = 'newlabel2' .lbl3.Caption = 'newlabel3' Endwith Endproc Enddefine Define Class TranslateTools As Custom Procedure Translater * Get the object raising the event Local Array EventArray(1) Aevents(EventArray, 0) oCtrl = EventArray(1) oCtrl.Caption = Translate(oCtrl.Caption) Endproc enddefineCetin