Hello,
I'm trying to make a stamp that will autofill with the user's responses, then apply conditional formatting. I've hit a dead end, though.
I was able to follow the how-to's and make a prompt when the stamp is applied to a document. The user's response shows up correctly. However, the conditional formatting is doing something a little odd.
It is using the previous response to calculate the conditional formatting. So if I answered "YES" the first time, it does nothing. Then by answering "NO" the second time, it erroneously colors it green. Then if I answer "YES" again, it erroneously colors it red. I'm guessing that's due to the fact that the value is saved into the stamp after it's applied to the document.
Is there a workaround for this so I can force it to calculate the conditional formatting between the time that the user provides an answer and the stamp is actually rendered?
Thanks!
var cAsk = "Auto Limits Acceptable? YES or NO" ;
var cTitle = "Auto Limits";
if(event.source.forReal && (event.source.stampName == "#AI4EGwWBhUBZb07sYZerWD"))
{
var cMsg = app.response(cAsk, cTitle);
event.value = cMsg;
event.source.source.info.DocumentState = cMsg;
}var q1 = this.getField("Auto Limits")
{
if
(q1.value == "NO")
(q1.textColor = ["RGB",1,0,0]);
else
(q1.textColor = ["RGB",0,0.667,0]);
}