Auto tab for crossword puzzle

New Here ,
Sep 01, 2021 Sep 01, 2021

Copy link to clipboard

Copied

I have a lesson plan that includes a crossword puzzle in a fillable pdf. I'm trying to make it so students can enter one letter per field and have the cursor automatically go to the next field. I've set all the fields (84 of them) in sequential order and they all have a character limit of 1. 

 

I've seen some java script for auto-tab, but I haven't gotten it to work properly yet. 

 

Does someone know how to get auto-tab to work in this situation?

Thank you!

TOPICS
JavaScript , PDF forms

Views

85

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
Community Expert ,
Sep 01, 2021 Sep 01, 2021

Copy link to clipboard

Copied

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
New Here ,
Sep 01, 2021 Sep 01, 2021

Copy link to clipboard

Copied

Thank you for this suggestion, but I'm not very tech savvy (always willing to learn, though!) I see the code for the fieldFull on the page you linked, but where does it go?

 

I added it to the document level java script and it doesn't make the cursor move to the next field.   

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
Community Expert ,
Sep 01, 2021 Sep 01, 2021

Copy link to clipboard

Copied

From that page:

This is a custom keystroke script for a text field that has a character limit.

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
Community Expert ,
Sep 01, 2021 Sep 01, 2021

Copy link to clipboard

Copied

You can apply it via Properties - Format - Custom - Custom Keystroke Script:

try67_0-1630532980963.png

 

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
New Here ,
Sep 01, 2021 Sep 01, 2021

Copy link to clipboard

Copied

Thank you for this. I do see the Format tab on the field, but I've pasted the code into the Custom Keystroke box and it's still not moving to the next field. Also, the code only pasted into the first field. When I tried to paste it into the Custom Keystroke box on text2 field, it won't go in there. Here's the code I pasted:

if ( event.fieldFull || event.willCommit )
this.getField("NextTabField").setFocus();

 

Is this correct? Do I need to paste it in each field? I wonder if there's someone I can hire to make this crossword puzzle work?

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
Community Expert ,
Sep 02, 2021 Sep 02, 2021

Copy link to clipboard

Copied

Yes, this seems correct, although you'll have to adjust the field name in the second line.

And yes, it needs to be applied to each field.

If you're interested in hiring someone to do it for you feel free to contact me privately via [try6767 at gmail.com].

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
New Here ,
Dec 10, 2021 Dec 10, 2021

Copy link to clipboard

Copied

Hi

It auto tabs after you hit the key twice. So not really an autotab?

Is there away to make advance without the extra key stroke?

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
Community Expert ,
Dec 10, 2021 Dec 10, 2021

Copy link to clipboard

Copied

LATEST

I assume you are talking about crossword puzzle so you want to autotab to next field when 1 character is entered in the field?

You can use this as "Custom keystroke script":

if(AFMergeChange(event).length == 1) this.getField("field2").setFocus();

 

Be aware when you enter script it will disappear but it will still work.

Change field name "field2" in script to your actual field name.

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