[I was going to give up and go home, but noooo, I'm stubborn] Ok, the trick is that inside the _add method of the ZClass, you don't have the Product in the Acquisition path. So inside the <dtml-with> of the standard _add method, you need to do something like <dtml-with "manage_addProduct['ProductName']"> <dtml-call "REQUEST.set('id', 'defaults')"> <dtml-call "InstanceData_add(_.None, _, NoRedir=1)"> <dtml-call "manage_addFolder(id='Instances')"> </dtml-with> aarggrgrgggg. Still, now I know... :) Anthony
Anthony Baxter wrote I've been hammering my head against this - I'm trying to get a folderish ZClass to add a couple of instances of a different ZClass to itself when it's created. I've looked at Kevin's ZClass How-to (the bit at the bottom of it needs a <pre>, btw) and I've tried various versions of trying to call the createInObjectManager inside the _add page of the ZClass... These all result in creating the object in the parent folder of the new folderish object.
I know I'm missing something really really stupid. Can someone help me here?
Anthony
-- Anthony Baxter <anthony@interlink.com.au> It's never too late to have a happy childhood.