Need a help with creating grep code
- This topic has 1 reply, 2 voices, and was last updated 9 years ago by .
- You must be logged in to reply to this topic.
Learn / Forums / General InDesign Topics / Need a help with creating grep code
Learn / Forums / General InDesign Topics / Need a help with creating grep code
Tagged: grep code
Hi,
Thanks for checking my question.
I do a regular Advertisement for a car company in indesign.
There are about 200 to 300 listing like below every week.
I need the below text converted to
2015, MITSU ASX, INTENSE, 1.8 DSL, CRUISE -ALLOYS-SAT NAV-BLUETOOTH-280 TAX, RED, 27750
2015(tab)MITSU ASX, INTENSE, 1.8 DSL, CRUISE -ALLOYS-SAT NAV-BLUETOOTH-280 TAX, RED(tab)27750
the problem is Start year and last price will be different for each listing.
I need a grep codes to do this task very quick
Hey Francis,
Try this, it should work for both as long as the comma and space between stay the same, they could also probably be split apart into two, but if it works why do it twice. This GREP only catches the comma-space at the beginning or at the end (it only see’s the numbers as reference using a lookahead and a keep), so the only thing you have to do is replace them with your tab.
Find: (^\d+\K, |, (?=\d+$))
Change: \t
To provide the best experiences, we use technologies like cookies to store and/or access device information. Consenting to these technologies allows us to process data such as browsing behavior or unique IDs on this site. Not consenting or withdrawing consent, may adversely affect certain features and functions.
To provide the best experiences, we and our partners use technologies like cookies to store and/or access device information. Consenting to these technologies will allow us and our partners to process personal data such as browsing behavior or unique IDs on this site and show (non-) personalized ads. Not consenting or withdrawing consent, may adversely affect certain features and functions.
Click below to consent to the above or make granular choices. Your choices will be applied to this site only. You can change your settings at any time, including withdrawing your consent, by using the toggles on the Cookie Policy, or by clicking on the manage consent button at the bottom of the screen.
You have to be logged in to save.
Not a member? Join Today - it's FREE!