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

Deleting text from multiple textfields in one action or key combination.

Explorer ,
Feb 01, 2019 Feb 01, 2019

It would be nice if InDesign could provide us with a key combination to delete text from multiple textfield in one single action. Now you have to select the text from each single textfield to delete its content.

4.1K
Translate
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 , Feb 02, 2019 Feb 02, 2019

Hi Jos,

if all the "cells" are text frames of their own, you could remove all ther contents this way:

1. Select all text frames

Note: The following will not work with a group.

Ungroup if you selected a group of text frames.

Or select all members of the group inside the group if all the members of that group are text frames.

2. Do a GREP Find/Replace action

Find pattern ( derived from winterm 's find pattern in reply #6 😞

\A.+\Z

Replace: Nothing

Do that on: Stories.

FWIW: winterm already gave you some good

...
Translate
Community Expert ,
Feb 01, 2019 Feb 01, 2019

If you have a feature request, file it here: Adobe InDesign Feedback

I suggest posting more detail than you have here. I'm not really sure what you're referring to.

Translate
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
Explorer ,
Feb 01, 2019 Feb 01, 2019

It's a single A4 page in InDesign with about 400 separate small text fields.

Translate
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 ,
Feb 01, 2019 Feb 01, 2019

As @winterm already said:

Staying in InDesign, it still may be possible using standard Find/Change capabilities, but we need to know more about your actual situation. Is there any other text in your document, or only text fields to be cleared? All text fields should be cleared, or just certain ones? How could you tell formally one from another: by applied style, manual text formatting, content?

Do you want remove characters or words or sentences?

Give good examples please. And also show us the document structure please. Perhaps with an example file?

Translate
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
Mentor ,
Feb 01, 2019 Feb 01, 2019

Here is one of possible approaches: if your longest text field is still shorter then the shortest story of a 'regular’ text, you can use this regex:

\A.{1,20}\Z

in this case, to locate any text story (effectively: text field) ranging from 1 to, say, 20 characters long, and change it to nothing, using F/C dialog GREP tab.

However, it's a shot in the dark, you should elaborate.

Translate
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
Explorer ,
Feb 01, 2019 Feb 01, 2019

It looks like an excel sheet but is build in InDesign.

I blurred some fields with private information.

I want to reuse this document and clear all text fileds with one action.

Op 1 februari 2019 om 16:26 schreef winterm <forums_noreply@adobe.com>:

Deleting text from multiple textfields in one action or key combination.

created by winterm https://forums.adobe.com/people/winterm in InDesign - View the full discussion https://forums.adobe.com/message/10906497#10906497

>

Translate
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
Mentor ,
Feb 01, 2019 Feb 01, 2019

Those links from above aren't useful. You can upload your file somewhere, and post a download link here, or just include a screenshot in your reply using Insert Image icon:

reply.png

Translate
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 ,
Feb 01, 2019 Feb 01, 2019

… but much more better than images are files or text examples.

Otherwise, we have to re-build your example …

Translate
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
Mentor ,
Feb 01, 2019 Feb 01, 2019

Sure, but OP mentioned fields with private info… It could be changed in a sample to some not sensitive but otherwise identical text though…

Translate
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
Explorer ,
Feb 02, 2019 Feb 02, 2019

Schermafbeelding 2019-02-02 om 15.18.04.png

Translate
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
Explorer ,
Feb 02, 2019 Feb 02, 2019

Thanks I uploaded a screenshot from a part of the A4 InDesign page.
All these text fields are separate and not linked to each other.

Translate
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 ,
Feb 02, 2019 Feb 02, 2019

Thank you.

But what exactly do you want to remove?

Can you share the relevant part as plain text or file (without private informations) for testing?

A shot into dark: If you want to remove the green digits:

\d{6}

with color green

replace with

[let the replace field empty]

Translate
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
Explorer ,
Feb 02, 2019 Feb 02, 2019

I want to remove all the text and numbers from all text fields.

Translate
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 ,
Feb 02, 2019 Feb 02, 2019

At first:

This is a table.

Do you have a header in your table?

One further question:

Why not easy go with the text cursor in the top left corner of your table (all contents will be selected) and delete?

Translate
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
Explorer ,
Feb 02, 2019 Feb 02, 2019

It looks like a table but these are all separate text fields.

Translate
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 ,
Feb 02, 2019 Feb 02, 2019

We are 'spinning in a circle'.

pixxxel schubser​ wrote

… And also show us the document structure please. Perhaps with an example file?

Translate
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
Explorer ,
Feb 02, 2019 Feb 02, 2019

Schermafbeelding 2019-02-02 om 16.18.07.png

Translate
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 ,
Feb 02, 2019 Feb 02, 2019

Sorry. But a screenshot isn't helpful in this case.

Please upload a simplified example INDD (eg Dropbox) and link to here and say your InDesign version

Translate
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 ,
Feb 02, 2019 Feb 02, 2019

Hi Jos,

if all the "cells" are text frames of their own, you could remove all ther contents this way:

1. Select all text frames

Note: The following will not work with a group.

Ungroup if you selected a group of text frames.

Or select all members of the group inside the group if all the members of that group are text frames.

2. Do a GREP Find/Replace action

Find pattern ( derived from winterm 's find pattern in reply #6 😞

\A.+\Z

Replace: Nothing

Do that on: Stories.

FWIW: winterm already gave you some good hints how to do that.

Regards,
Uwe

Translate
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
Explorer ,
Feb 02, 2019 Feb 02, 2019

Hi Laubender,

CMD+F > GREP > Search for: \A.+\Z > replace into: nothing.
That was exactly what I was looking for. Thanks!

Witerm gave same advise with \A.{1,20}\Z and \d{6} from PS.

Is there a list of codes like these or some  background information on the Adobe website or somewhere else on the web available?

Thanks again, Jos

Translate
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
Mentor ,
Feb 02, 2019 Feb 02, 2019

Putting aside all that GREP stuff, what I gathered from all the posts above:

It looks like a table but these are all separate text fields.

You mean, all these numbers are put to text frames, which are separate text stories each? Huh, man, that's tough… It's hard to believe someone still works in a such manner these days. I wish they would be a bit more lazy.

I think I will rebuild the file as a table.

Definitely! This kind of data layout CRIES for a table loud and clear! Well, let's say, you will empty all text fields you think you need to, and… what? How on earth you're going to reuse this pain in the a*s? Manually entering new data, one by one? Then I wonder, in what format you get new data from client? Usually office people use table(s) in Word/Excel, and that table(s) can be easily placed/replaced and formatted/edited in InDesign layout. So much simpler to handle just one table than 400 small text stories.

That said: you actually don't need to delete anything. You need to rebuild this *masterpiece* as a table (better - just make a new table from scratch), and maybe - rethink your workflow.

When you will have a correct table, editing/deleting/updating data will be so simple. Not even worth to mention.

Translate
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
Explorer ,
Feb 02, 2019 Feb 02, 2019

I am very used to work with tables in daily workflow.

It may look strange to work this way but it forces me to fill each single field with the right numbers and information.

Checked Youtube for GREP styles. This a great functionality which didn't knew of until today.
We can close this discussion now


Thanks again!

Translate
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 ,
Feb 02, 2019 Feb 02, 2019

You can mark helpful answers and one correct answer. (A correct answer shows: this thread is solved.)

Translate
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
Mentor ,
Feb 03, 2019 Feb 03, 2019
LATEST

I hate to post to already 'answered' threads, but this time a little comment may be useful to other lurkers, not OP.

* It may look strange to work this way but it forces me to fill each single field with the right numbers and information. *

Never agree to work with hundreds of small text chunks to mimic a table. Sooner or later, it will lead you to problems, not to mention how it is inefficient to work this way.

If it is a person who insists on this, he's just not competent to make decisions.

If it is a workflow requirement, such a workflow is obviously faulty, and must be re-thinked.

Now to the GREP.

* winterm gave same advise with \A.{1,20}\Z and \d{6} from pixxxel schubser . *

oh, it's not the same, not at all… Both regex'es above are restricted to some special content, or amount of content.

If one wants to empty, but not delete ALL text frames:

\A.+\Z will likely work just fine in your *table*, but be aware: stories with line breaks will be ignored.

.+ grabs all text, but leaves out line break(s) itself.

only (?s).+ will indeed clean up all text frames 'to the bone', not taking into account actual content.

Translate
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
Explorer ,
Feb 02, 2019 Feb 02, 2019

I think I will rebuild the file as a table. Then I can select all text or part of it as desired and my problem or question is solved. Thanks a lot foor all the advice and tips.

Translate
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