>>I already have code that can walk through an object and recreate it, then add properties I guess, but the problem is that it's slow. If you have a largish array this will be dreadfully slow and all that just to get an object structure in this case.
>
>How about something like:
>
>
oTest = createobject('form')
>?oTest.Caption
>oTest.Caption = 'New Form Class'
>oTest.SaveAsClass('c:\vfptest\temp', 'temp')
>oTest = newobject('temp', 'c:\vfptest\temp')
>?oTest.Caption
>
I don't think that works with PRG classes. It also doesn't deal with surrogate objects. See my other reply here - I ended up going the brute force route creating the object and then copying the properties.