LOCAL oSeries, myObject >external array oSeries > >oSeries=This.Parent.Series > >IF oSeries.Count=1 > myObject=oSeries(1) >ELSE > myObject=oSeries >ENDIF>
*In the Main PRG *(some code) SET PROC TO OtherPRG.PRG ADDI MyObject=CREATEOBJECT("SomeObject") *(more code) *Other PRG * I have to add "DIME oSeries[1]" here DEFINE CLASS SomeObject AS Custom FUNCTION INIT() *(some code) This.AddObject("Serie","SerieClass") This.AddObject("Problem","ProblematicClass") ENDFUNC ENDDEFINE DEFINE CLASS SerieClass AS Collection *(some code) ENDDEFINE DEFINE CLASS ProblematicClass AS Custom *(some code) FUNCTION WithTheProblem LOCAL oSeries,myObject,(others ...) * ok now with "EXTERNAL ARRAY oSeries" here oSeries=This.Parent.Series IF oSeries.Count=1 myObject=oSeries(1) ELSE myObject=oSeries ENDIF *(other code...) ENDFUNC ENDDEFINEThanks again for your time :-)