Passing a button value as PV to a Process

Hello All,

I am using an interface to invoke a Process Model to download my claim report. I am able to invoke the process and download the report successfully. But the problem is, when I am trying to invoke a condition such as If the button pressed is Download, I should download the file and if it is Email, I should email the report instead.

For this scenario, I am using Button Widget to save the information of the form and filters. And the button value, I am saving into the variable local!buttonValue. Now, my questions are

1. I am not able to access the values from save!into in the process I am invoking. How can I access these variables?

2. How can I access the buttonValue as a PV inside the process I have designed?

3. I have tried doing this  saveInto: {local!export, a!save(ac!buttonValue, cons!CLAIMREP_BUTTON_VALUES[2])}. But when I am using the condition if ac!buttonValue = 1, I am getting the error, variable not found ac!buttonValue.

can you please suggest?

 

Edit: To add to this, I cannot use ri variable to share the data. Adding the ri variable is invalidating the interface with an error "Expected 1 parameter, passed 0 parameters"

 

Thanks,

Adi

  Discussion posts and replies are publicly visible

Parents Reply
  • 0
    Certified Lead Developer
    in reply to AdirajuB

    Incase if you are using two linkfields one for "Download" and One for "Email", Try using the below code:

    {
      a!linkField(
        label: "Send as Email",
        links: a!submitLink(
          value: {
            local!ClaimID: local!ClaimId,
            local!ClaimantID: local!ClaimantID,
            local!buttonValue: "Send as Email" /*Recommended to use the constant*/
          },
          saveInto: local!export
        )
      ),
      a!linkField(
        label: "Download",
        links: a!submitLink(
          value: {
            local!ClaimID: local!ClaimId,
            local!ClaimantID: local!ClaimantID,
            local!buttonValue: "Download" /*Recommended to use the constant*/
          },
          saveInto: local!export
        )
      )
    }

Children