Page 1 of 1

Cloning many form objects

Posted: Sun Dec 16, 2012 4:17 pm
by martbarr
Just tried to clone one of my forms which has loads of objects and found that the form clones ok but the objects don't.
Is there a way to clone the form AND it's objects?
I don't fancy cloning loads of objects individually because we will need to do this a good few times as we develop.

Thanks as always
Martin

Re: Cloning many form objects

Posted: Wed Dec 19, 2012 1:31 pm
by martbarr
I expect that I can select the objects using a query into a temp table and then amend the formID and regenerate a PrimKey.
And then import back to object table?

Re: Cloning many form objects

Posted: Thu Dec 20, 2012 2:02 am
by admin
Martin,

You are correct but you'll also need any objects on any Subforms on that Form.

Steven

Re: Cloning many form objects

Posted: Sat Dec 22, 2012 2:25 pm
by martbarr
thank you Steven

I've just written a small python script to do this - saved me a bit of time !
But I guess most of us won't want an exact clone - but better to delete objects off a form than add them on individually.
It might be handy to have an index page button which did an entire form clone (just a thought)
(or a page of advanced utilities that we might use "sometimes")

thanks
Martin

Re: Cloning many form objects

Posted: Wed Dec 26, 2012 11:32 pm
by admin
Martin,

If you had written it in PHP you could have shared it with us as a Activity Procedure!

Steven