Page 1 of 1
Pui.Download Question
Posted: Mon Nov 17, 2014 12:55 pm
by AjFromADS
In my RPG program, I generate and fill a Temporary IFS File, then I fill a field on the screen with the name of that file.
I'm looking for a way to fill the ID parameter of Pui.Download API With what's in that field.
I'm not familiar with JavaScript, so any help would be much appreciated.
Thanks,
AJ
Re: Pui.Download Question
Posted: Mon Nov 17, 2014 1:07 pm
by negley
In javascript, all you would need to do is:
pui.download({ "id": get('OutputField1') });
get( ID ) -- Make sure you find what the ID of your dynamic output field would be. The ID is different than what you bind for RPG.
http://www.profoundlogic.com/docs/displ ... %28+id+%29
I assume that you are using a button, so this would go onto a onclick() property of the button.
Re: Pui.Download Question
Posted: Mon Nov 17, 2014 1:59 pm
by AjFromADS
Alright, I got that all coded, but now I'm getting an alert box that says:
Onclick Error:
Get is not defined.
Re: Pui.Download Question
Posted: Mon Nov 17, 2014 3:00 pm
by Scott Klement
Javascript is a case-sensitive programming language. The error message complains of Get not being defined -- that's because it should be 'get' (all lowercase). In Javascript, get and Get are two different things, because it's case-sensitive.