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

Setting up and formatting a large program guide

Community Beginner ,
Mar 23, 2018 Mar 23, 2018

Hi.
I'm pretty experienced with inDesign, and am familiar with data merge as well as some *light* scripts, so I'm not looking at getting a step by step so much as a point in the right direction, I just really can't wrap my head around this specific issue.

The end result I want is just a simple program guide, the current designer has made it using tabs however I would think a table would work better for automation (?)
Here's how it will look:
help_image.jpg

But here is how I receive the info:


@restaurant
@centre:Bonsor

@normal:F, January 19

@normal:11am-2:30pm

@centre:$9.65

@normal:456692



It's an export from some program, comes as plain text and they currently have someone fix it up in Word THEN put it into indesign, I am to obsessive about automation to do this in such a crazy way. Let's assume we I can't get the exported info to change, I wonder if I can automate something to break this into a table, then use the table with datamerge? Or am I stuck just copy and pasting until they change the work flow?

597
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

Valorous Hero , Mar 23, 2018 Mar 23, 2018

It would be best if the complete data as received for the 6 examples of finished formatting was supplied, perhaps as a text file uploaded someplace and linked here.

The @ symbol, data type (or style name) followed by a colon is certainly similar to tagged text. But if each piece of the data is on separate lines and the lines are to whatever degree out of order as shown in the bit of sample text, then it would require a bit more work than it seems it could/should be.

It may help you to find out whe

...
Translate
Valorous Hero ,
Mar 23, 2018 Mar 23, 2018

It would be best if the complete data as received for the 6 examples of finished formatting was supplied, perhaps as a text file uploaded someplace and linked here.

The @ symbol, data type (or style name) followed by a colon is certainly similar to tagged text. But if each piece of the data is on separate lines and the lines are to whatever degree out of order as shown in the bit of sample text, then it would require a bit more work than it seems it could/should be.

It may help you to find out where this data is stored. It may be as "simple" as getting them to change their export routine to a format that would be more in the order you need it to be. I've done this with several clients over the years, especially from the clients that have transitioned from XML to tagged text. And for some, I get the raw data and get it imported into Access and push it back out in the order I need (and as tagged text).

It may be that after seeing the data for the 6 examples that a Perl regex in a good text editor could rearrange the data as well. And then strip the @ tags, leaving just the location name set for its different, italicized styling. Maybe, probably. Once the regex worked, it could be scripted. Which would be worthwhile to do if this will be a recurring job.

Mike

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 ,
Mar 24, 2018 Mar 24, 2018

The end result I want is just a simple program guide, the current designer has made it using tabs however I would think a table would work better for automation (?)

I don't see why a table would help with this. The lines can be easily formatted with paragraph styles. The tab stop positions in the two lines with tabs can be included in the paragraph style and the space between the events can be handled via space above in the first paragraph's style.

So if the text can be cleaned up via regex as Mike suggests, with a single empty paragraph return between events as a marker, then a fairly simple script could do the formatting

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 Beginner ,
Mar 26, 2018 Mar 26, 2018

I wanted it in a table because I've used the work flow of table> datamerge> script> to make it all one text box instead of separate pages, plus I thought spreadsheet would be easier for other people to wrap their head around and for making changes/fixing errors.

Thanks everyone! I have solved this by having them export their data differently. Not sure what the end result will be but if they can properly tag the info I can use GREP styles, and if they can export as a spread sheet I can do the workflow I mentioned above.

Thanks so much!

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 ,
Mar 26, 2018 Mar 26, 2018

If you are doing something like this in the future where the sections are all the same number of lines, the formatting can be done with one click by setting up Paragraph Styles with Next Styles applied with the last style applying the first style as next.

I didn't suggest earlier because it looks like you'll have a mix of 3-line and 4-line sections.

Here I have repeating 4-line sections. Selecting all of the text I right-click in the Paragraph Styles panel to apply the looping styles:

snap3.png

Screen Shot 8.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 Beginner ,
Mar 26, 2018 Mar 26, 2018

Whoooooo. Yes, looping styles, I've heard of this but never tried it. Thank you!

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 ,
Mar 26, 2018 Mar 26, 2018
LATEST

Excellent suggestion, Rob. You can make it working with multiple data lines IF you keep a "placeholder" for the missing data (usually an empty return). After you format the text, just use the GREP Find/Replace multiple returns.

The OP would still need to clean up the data file to get the three data points one one line with tabs.

David Creamer: Community Expert (ACI and ACE 1995-2023)
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 ,
Mar 24, 2018 Mar 24, 2018

I did a number of 700-1200 page directories with a similar data layout. I used the Em Software InData plugin and could do the actual 1000 page flow in about 2-3 hours.

If the data is coming from a database, it looks like it was altered after-the-fact since database output does not look like what you show. For InData to work, the data would have to be in more of an Excel-type format.

If you don't want to use InData or can't get the data in a better format, based on the info, I would stick with tabs. However, I would find out if the data output can be changed to remove the "@xxxxx:" info. If not, a Find/Replace macro in Word can clean it up nicely.

It looks like the the date, time, and 6-digit code can be formatted with tabs with a Word macro too--as long as the pattern is consistent.

David Creamer: Community Expert (ACI and ACE 1995-2023)
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