Setting an crossreference table object in click event

I have a main table called Claims.
I have another table called Contacts which holds all contacts of different kinds.
In between I have a table called Insured which is a one to many table between Claims and Contacts. One claim can have many Insured Contacts. The insured table holds the ClaimID and the ContactID

So my issue is this. From the Edit Claims page, I want to go be able to add a new Insured which would include a new Contact. But right now it shows me just the two fields from the Insured table.

What I want to do is have the form show a new Contact page and then when the user hits save, Save the contact first, then save a new Insured object based on the ID I get from the saved Contact.

Is there a way to do this within the Click Handler dialog? Right now I have the createContact method execute. I'm hoping there's a way to get the id from the createContact method and then set the insuredID before calling a createInsured method.

I got it to work. I'm impressed.

So you can get the ID from an object after it is saved.
First I Invoked the createContact method sending the ${contact} object

Then I just set the property insured.ContactID= ${contact.ContactID}

And it worked!!!