• Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
    Dedicated community for Japanese speakers
  • 한국 커뮤니티
    Dedicated community for Korean speakers

Dynamic Stamp Javascript Window Popping Up When Hovering Over Stamps > Dynamic

New Here ,
Nov 01, 2022 Nov 01, 2022

Copy link to clipboard

Copied

Hi all, I've created a custom stamp and used this.selectedAnnots[0].AP to identify the stamp name but the 

dynamic stamp javascript window pops up when hovering over stamps. The code is as follows:

var cAsk1 = "Enter status of check: ";
var cMsg1 = app.response(cAsk1);
var cAsk2 = "Enter any comments:";
var cMsg2 = app.response(cAsk2);

if(event.source.forReal &&
   (event.source.stampName == "#6WPNYFVTC7VYpeOsBS5RmA"))
{
    AFDate_FormatEx("h:MM tt, mmm dd, yyyy");
    event.value = event.source.source.documentFileName + (new Date()).toString() + "CHECKED BY: " + ((!identity.name ||     identity.loginName != (event.source.source || this).Collab.user) ? (event.source.source || this).Collab.user : identity.name) + " AT " + event.value + "\n" + "CHECK STATUS: " + cMsg1 + "\n" + "COMMENT: " + cMsg2;
}

 

Any suggestions are welcome

 

TOPICS
Acrobat SDK and JavaScript , Windows

Views

33

Likes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines

correct answers 1 Correct answer

Community Expert , Nov 01, 2022 Nov 01, 2022

Move the first lines of code to be within the if-clause.

Likes

Translate

Translate
Community Expert ,
Nov 01, 2022 Nov 01, 2022

Copy link to clipboard

Copied

LATEST

Move the first lines of code to be within the if-clause.

Likes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines