Question

1
Replies
1815
Views
JOHNPW_GCS Member since 2009 20 posts
PEGA
Posted: 3 years ago
Last activity: 3 years 8 months ago
Closed
Solved

Javascript Function: Best way of setting PRPC Property to return value ?

I'm using a Javascript library which has functions which returns values (usually Strings); like this (toy) example:

function MyFunction() {
		return "This was set from JS.";
}

I need to set a PRPC Property to the return value of the function; what's the best way of doing this ?

Is there something more elegant than the following for instance:

1. Create PRPC Property 'RetValue'.

2. Place this on a Section ; but hide it from users.

3. Run the JS in the same Section.

4. Within the JS; locate the PRPC Property's HTML using Javascript (getElementByID ? but what *is* the ID ?); and update the HTML with the value.

5. Then the PRPC Section will hold the updated value ; but the Clipboard will NOT; but (will it?) when we move to the next screen in the flow - will the value be automatically added to the Clipboard ?

Is there an actually PRPC Javascript library for doing this sort of thing already ?

Thanks in advance,

John

***Updated by moderator: Lochan to add Categories***

Data Integration Java and Activities User Interface
Moderation Team has archived post
Share this page LinkedIn