>lparameters tlEnabled, toObject > >if vartype(m.toObject) <>"O" > toObject = this >endif > >local lnI, lcBaseClass, loObject >local array laIgnoreClasses[1] >store space(100) to laIgnoreClasses[1] >alines(laIgnoreClasses, this.cClassFilter,", ") > >for each m.loObject in m.toObject.objects > if not ascan(laIgnoreClasses,upper(m.loObject.baseclass)) > 0 ; > and not upper(m.loObject.parentclass) = [ABIZOBJ] > if pemstatus(m.loObject, "OBJECTS", 5) && Container object > this.SetEnabledStatus(m.tlEnabled, m.loObject) && Call the method recursively > else > if pemstatus(m.loObject, "Enabled", 5) > if not pemstatus(m.loObject, "lOriginalEnabledStatus", 5) > m.loObject.addproperty('lOriginalEnabledStatus', m.loObject.enabled) > endif > m.loObject.enabled = m.loObject.lOriginalEnabledStatus and m.tlEnabled > endif > endif > endif >nextWell, I wouldn't worry about the speed too much. But you might use WITH/ENDWITH here. It is said that it will improve speed. And also you might write another routine that's called only once and adds the property to the objects. However, that scenario is only valid if you don't add objects dynamically.