Skip to main content
Participant
July 17, 2024
Question

Execute actions upon selection from a popup

  • July 17, 2024
  • 1 reply
  • 221 views

I need an action to happen then the user selects yes and to cancel signature when they select no.

Current Code:

var SignatureField1 = this.getField("SM Signature");

var nButton = app.alert({cMsg: "If you have a Common Access Card (CAC) to digitally sign, please select Yes. If not, please select No and apply a manual signature when required.",

cTitle: "Question ?",

nIcon: 2,

nType: 2});

if (nButton != 4 ) {

SignatureField1.access = "protected";

}

 

I need a Warning popup to appear with only the "OK" option prior to digitally signing. I also need to stop the digital signature process to discontinue or attempt to find a signature when the user selects "No". I do not know where or what I need to input the additional code in this code to execute I need. The original popup works fine but won't execute what I need it do or stop it from trying to sign when I need it to stop.

 

Can someone please help me with this situation?

This topic has been closed for replies.

1 reply

Nesa Nurani
Community Expert
Community Expert
July 18, 2024

Do you use script in a button or in a signature field?

You could set signature to readonly or, even better, hide it until user select 'Yes' from alert.