Transfer values from form to frame

Transfer values from form to frame

Postby TirasX » Tue Jun 14, 2016 6:13 pm

Hello,
I am new to nuBuilder an try to transfer values from an form to a frame. I can successful open the frame with an custom button (Code:nuOpenFormInFrame('575d8c759e630de',id);)
In the opened frame I want to predefine some vaules that should be get from the opened form in backgroup or pushed with "nuOpenFormInFrame".
How can I realize that?

Many thanks to the team of nuBuilder an your help.
TirasX
 
Posts: 8
Joined: Tue Jun 14, 2016 5:59 pm

Re: Transfer values from form to frame

Postby TirasX » Wed Jun 15, 2016 7:32 am

I have found a solution myself. :D
On source form I created a button with the folowing code to set the hash variables:

Code: Select all
nuSetHash('myterritory', '#territory_id#');
nuSetHash('mypublisher', '#publisher_id#');
nuOpenFormInFrame('575d8c759e630de','','');


On the target form I used Javascript under custom code.

Code: Select all
$('#territory_id').val(nuGetHash('myterritory'));
$('#publisher_id').val(nuGetHash('mypublisher'));
$('#territory_id').change();
$('#publisher_id').change();
TirasX
 
Posts: 8
Joined: Tue Jun 14, 2016 5:59 pm


Return to Custom Code