Skip to main content
Inspiring
March 6, 2025
Answered

Script: Extract text field names of all interactive forms

  • March 6, 2025
  • 2 replies
  • 232 views

I have a document with lots of interactive form fields to translate and I'm trying to figure out a way to extract all the text field names at once. Does anyone know a script to achieve this? Any help will be greatly appreciated.

 

Correct answer TᴀW

This script should do the trick. (No AI involved :-), so it actually works!)

pp = document.pages.everyItem().getElements();
s = [];
for (i = 0; i < pp.length; i++){
	f = pp[i].tabOrder;
	for (j = 0; j < f.length; j++){
		s.push(f[j].name);
	}
}
prompt("All fields, ready to copy...", s.join("\r"));

2 replies

TᴀW
TᴀWCorrect answer
Legend
March 6, 2025

This script should do the trick. (No AI involved :-), so it actually works!)

pp = document.pages.everyItem().getElements();
s = [];
for (i = 0; i < pp.length; i++){
	f = pp[i].tabOrder;
	for (j = 0; j < f.length; j++){
		s.push(f[j].name);
	}
}
prompt("All fields, ready to copy...", s.join("\r"));
Robert at ID-Tasker
Legend
March 6, 2025

How will you be translating your file? 

 

If by some professional company / person - you can give them IDML file.

 

If it's a DIY project and If you work on Windows - I could give you access to the full version of my ID-Tasker tool for a few days for free. 

You could use it to export and then import back all of the names - and other elements in your document.