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

"Remove Blank Lines" in Data Merge is Overriding Paragraph Styles

New Here ,
Feb 26, 2023 Feb 26, 2023

Copy link to clipboard

Copied

[InDesign 18.1, Mac)S 11.7.4]

How to "Remove Blank Lines" without affecting paragraph styles?

 

I'm designing cards for a board game. The client requested that each card ability have a distinct background and border, so I've made different Paragraph Styles for each. Each ability is its own column in the spreadsheet. No cards have all ability types, but most cards have a mix of 2 or 3. You can see them linked here with the Paragraph Style applied to each one.

Screen Shot 2023-02-26 at 9.22.59 AM.png

When I preview this normally, here's how one of the cards looks. I'd like to automatically remove those blank variables from the deck when I create a merged document.

d61466ae0653b49d.png

If I use activate "Remove Blank Lines..." in Content Placement Options, I get paragraph style overrides. In the example below, the previous page had a blank variable for the second paragraph, so it was deleted. However, that means the second paragraph on this page has the first Paragraph Style. 

acd1858ca9d8f666.png

Over the course of an entire deck, eventually all paragraphs in this text field get the first Paragraph Style instead of keeping their own.

 

I saw some bug reports that this has been fixed in InDesign v17.1, so I'm not sure why it's still occurring in 18.1.

 

tl;dr: Any advise for how to delete these blank lines without overriding the paragraph styles? I'd really prefer to do this at the data merge level rather than a post-merge script or search-replace.

TOPICS
Bug , EPUB , How to , Print

Views

520

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 , Feb 26, 2023 Feb 26, 2023

There is a very long thread from 2013 at https://community.adobe.com/t5/indesign-discussions/multiple-record-data-merge-into-paragraph-styles-applies-the-wrong-style/td-p/5633549#5883785 that covers this problem and has a scripting solution worked out by Uwe Laubender.

Votes

Translate

Translate
Community Expert ,
Feb 26, 2023 Feb 26, 2023

Copy link to clipboard

Copied

There is a very long thread from 2013 at https://community.adobe.com/t5/indesign-discussions/multiple-record-data-merge-into-paragraph-styles... that covers this problem and has a scripting solution worked out by Uwe Laubender.

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
New Here ,
Feb 26, 2023 Feb 26, 2023

Copy link to clipboard

Copied

That is indeed a long conversation! I tried the gist of their solution:

 

After merging the document without removing blank lines, here's how one page looks:

Screen Shot 2023-02-26 at 11.12.23 AM.png

 

I ran a text search for <FEFF>, resulting in only a few the blank lines being deleted, but generally cleaning up the document for the next step.

 

Screen Shot 2023-02-26 at 11.16.39 AM.png

 

Then I ran a GREP search for ^\s+ which deletes any remaining blank lines, all without affecting the other paragraph styles! Huzzah!

 

Screen Shot 2023-02-26 at 11.20.09 AM.png

 

It would've been nice to make this an automatic process before the merge, but at least this is a reliable backup option. If anyone has ideas for making it automatic, I'm all ears!

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
New Here ,
Feb 26, 2023 Feb 26, 2023

Copy link to clipboard

Copied

@Peter Spier I found one small hitch in this solution. It results in one extra white space character at the end of the text, making a gap from the bottom of the text frame. (This text frame is set to flow from the bottom):

 

daniels59958_0-1677429667302.png

 

I'm not sure what that special character is. I can't select it, but I can manually delete it, resulting in what I would prefer the text to look like. 

daniels59958_1-1677429745577.png

 

Any idea what I should be searching for to get rid of that one last pesky blank line?

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
New Here ,
Feb 26, 2023 Feb 26, 2023

Copy link to clipboard

Copied

LATEST

@Peter Spier Oh! I figured it out. Just GREP searched and deleted \r\z and that did the trick. Thanks again!

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