Back

If your email is not recognized and you believe it should be, please contact us.

  • You must be logged in to reply to this topic.Login

Turn on italics and turn off using code

Return to Member Forum

  • Author
    Posts
    • #55743
      jonsmilburn
      Member

      Due to the database source, my client can only give me the text as formatted below and it's a very long doc.

      This is an example of what I am trying to do.

      Make the below (the start/stop code may be different in the final)

      Text text @@::>Johnson & Johnson Case study@@::< text text

      Look like this

      Text text Johnson & Johnson Case study text text

      Just italicizing what is inside the codes and deleting the codes.

    • #55748
      Roland
      Member

      You could use a GREP search for this, separating the three parts (“@@::>”, the text and “@@::<”) and turn on a style on the just the text, ignoring the start & stop codes.

      Edit: I figured it out :)

      Do a GREP search for: (@@::>)([w -]+.+)(@@::<)
      Change to: $2
      Create a character style for the italic text and, using the Change Format option, apply that style to the search result.

    • #55756
      jonsmilburn
      Member

      Roland, You Rock!

      Works like a charm. Do you know of a good reference for GREP code?

      Thanks! Jon

    • #55759

      Peter Kahrel's e-book “GREP in InDesign CS3/CS4” has occasionally been called 'best value for money': https://oreilly.com/catalog/978&#8230;..596557348/

    • #55766
      Roland
      Member

      jonsmilburn said:

      Roland, You Rock!

      Works like a charm. Do you know of a good reference for GREP code?

      Thanks! Jon


      Good to hear it worked for you :)
      I'm not good at GREP, but trial & error (using GREP in a Paragraph style to see if the code works before doing a find & replace) and help on these forums have gotten me able enough to use GREP more and more lately. I'm learning as I go right now, but I think I'll check out the ebook Jongware mentioned.

Viewing 4 reply threads
  • The forum ‘General InDesign Topics (CLOSED)’ is closed to new topics and replies.
Forum Ads