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

Is there a way to make the pop ups show when people tab through the document?

Community Beginner ,
Mar 25, 2024 Mar 25, 2024

Copy link to clipboard

Copied

Hello
Is there a way to make the pop ups show when people tab through the document to fill it in? I created a fillable PDF  but the pop ups only show up  when  I hover over the area with the mouse.  

TOPICS
Create PDFs , Edit and convert PDFs , How to , PDF , PDF forms

Views

466

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
Community Expert ,
Mar 25, 2024 Mar 25, 2024

Copy link to clipboard

Copied

What do you mean by "Popup"?

 

Thom Parker - Software Developer at PDFScripting
Use the Acrobat JavaScript Reference early and often

Votes

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
Community Beginner ,
Mar 25, 2024 Mar 25, 2024

Copy link to clipboard

Copied

a button you add to have instructions pop up when people are filling out a document. right now you hover over the area for it to provide guidance before you fill it in. The instuctions do not pop up if you tab through. 

Votes

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
Community Expert ,
Mar 25, 2024 Mar 25, 2024

Copy link to clipboard

Copied

The "hover" text is a tooltip.  What you want is different. For clarity, you want to place a button on the form that when pressed displays a popup text box with instructions? 

There are a few ways to do this, most of them require scripting.

Here's a non-scripting method. One of the actions for field is "Show/Hide a form field". 

To use it:

1) Create a text field.

    a) Add the help text as the default value for the field.

    b) Place the field where you want it to popup.

    c) Set the field properties to read-only and hidden.

    d) Set the Field MouseExit Action to hide the field.    

2) Create a button for activating the text field. 

     a) Place it adjacent to the popup.

     a)  Set the MouseUp Action to show the text field

 

 

Thom Parker - Software Developer at PDFScripting
Use the Acrobat JavaScript Reference early and often

Votes

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
Community Beginner ,
Mar 25, 2024 Mar 25, 2024

Copy link to clipboard

Copied

So this is what I did, the problem is that when people tab through the document it does not trigger the pop up instructions. I need to know if there is a way to have teh pop ups show if you hover or if you tab through. 

 

Votes

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
Community Expert ,
Mar 25, 2024 Mar 25, 2024

Copy link to clipboard

Copied

You cannot change the behavior of the built-in tooltip.

But you can add your own. The instructions I provided above show how to do this using a button to activate a popup text field that shows help text. But you could also use the OnFocus or MouseEnter Actions on individual fields to do the same thing.  

Thom Parker - Software Developer at PDFScripting
Use the Acrobat JavaScript Reference early and often

Votes

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
Community Beginner ,
Mar 25, 2024 Mar 25, 2024

Copy link to clipboard

Copied

The instructions you gave above are how to make it work for hovering over an area, not for tabbing through. Are there specific instructions for it to work while tabing through as well as hovering so both functions are on the same PDF?

Votes

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
Community Expert ,
Mar 25, 2024 Mar 25, 2024

Copy link to clipboard

Copied

If you use the On Focus event to trigger showing the "tooltip" field, as Thom described, it will work when you tab into it as well as click into it.

Votes

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
Community Beginner ,
Apr 02, 2024 Apr 02, 2024

Copy link to clipboard

Copied

Do i add this as an additional action to the button properties or do i need to create a whole new button? Once i add "On Focus" to the "Select Trigger" Drop down, what goes sinto the "Select Action" drop down? Any chance you'd be willing to provide a step by step?

 

 

Votes

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
Community Expert ,
Apr 02, 2024 Apr 02, 2024

Copy link to clipboard

Copied

To display the popup help text when the user tabs or clicks into a field, add a hidden text field on the page named "HelpText". 

Next add the tooltip text (in the field properties dialog) to every field where the popup will be used. 

The the code needed to make this scheme work goes  into the OnFocus for every field where the popup will be used.

Here's an outline of the code (note this is not  actual working code)

 

 

 

var oHlpFld = this.getField("HelpText");
// Put tooltip text for field into popup
oHlpFld.value = event.target.userName;

// Find popup location, this should be next to the field with focus, 
// but not overlapping it. 
var oHlpRect = ... geometry calculation using event.target.rect ... 
oHlpFld.rect = oHlpRect;

// Display popup help text
oHlpFld.display = display.visible;
 

 

 

 

Next add code to the OnBlur to hide the popup

 

 

this.getField("HelpText").display = display.hidden;

 

 

 

You can read about page and field geometry here:

https://www.pdfscripting.com/public/PDF-Page-Coordinates.cfm

 

Thom Parker - Software Developer at PDFScripting
Use the Acrobat JavaScript Reference early and often

Votes

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
Community Beginner ,
Apr 02, 2024 Apr 02, 2024

Copy link to clipboard

Copied

I am no expert at all with this. Have no idea what teh above referes to and dont knwo how to add script. So far i ve been watching you tue videos which provide step by step guidance. I do not know where any of what you mentioned above is within the tools.  I need instrcution like once in properting click on Actions tab, then click slect trigger drop down and chose On Focus field, then from the Select action drop down select___. Yuo say att the tool tip text i assume you mean click options tab then add the tool tip or pop up text to teh Drefualt Value box, correct? Sorry i am very green at this ...

Votes

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
Community Expert ,
Apr 02, 2024 Apr 02, 2024

Copy link to clipboard

Copied

LATEST

What you are asking for is beyond the scope of free help on a forum.  If you need that level of instruction, then you should do one of two things.

1) Spend some time learning to use and script Acrobat. 

2) Hire a developer to do it for you. 

3) Stick with the built-in tooltip functionality.

 

 

Thom Parker - Software Developer at PDFScripting
Use the Acrobat JavaScript Reference early and often

Votes

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
Community Expert ,
Mar 25, 2024 Mar 25, 2024

Copy link to clipboard

Copied

You should do some experiments with the different field Action Events, MouseEnter, MouseExit, Focus and blur to understand how they work. 

The Focus event is triggered when a field is clicked or tabbed into.  The Blur event is triggered when a field has focus and losses it.  The MouseEnter is triggered when the mouse passes into the field area, and Mouse exit is triggered when the mouse leaves the field area.  You can use these events to show/hide a text field with instructions.   

 

I'm not sure it is a good idea to use a text field popup for each form field.  You'll have tons of hidden text fields to manage. 

What I've done in the past is to create help buttons, that popup text when the mouse hovers over them.   The help popup covers a group of fields.  

 

 

Thom Parker - Software Developer at PDFScripting
Use the Acrobat JavaScript Reference early and often

Votes

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