Quantcast
Channel: Adobe Community : All Content - LiveCycle Designer
Viewing all articles
Browse latest Browse all 5571

Stopping a Script under given conditions??

$
0
0

I am using the signature block with a Yes and No question message in the "PreSign" as follow:

 

var nButton = app.alert({ 

cMsg: "Warning: This step finalizes your report. You will no longer be able to edit it. \n\nDo you want to continue?", 

cTitle: "READY FOR PUBLICATION", 

nIcon: 1, nType: 2 

})

if(nButton == 4)

{// A yes Response

  // Code for doing the thing you do on a yes

  console.println("The Response Was Yes");

}

else if(nButton == 3)

{ // No Response

   console.println("The Response Was somthing other than Yes: " + nRtn);

}

 

I was hoping to get the script to stop going to the signature block (or any further) if the user chooses "No"??

 

If you are wondering , I am planning to turn the report "ReadOnly" in the "Click" event. Not using the lock option of the Signature block because it makes the file too big for my purposes (ie: almost double the size of the file)

 

Any help would be much appreciated.


Viewing all articles
Browse latest Browse all 5571

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>