GREP reference; need end-of-paragraph expression

GREP reference; need end-of-paragraph expression
I'm doing a canned GREP search to delete all trailing zeros. So if I have a number like 8.2500, it changes it to 8.25.
I have the code to find zeros leading up to a space, line break, and paragraph return but I can't find the expression for an end of paragraph. With hidden characters on, it looks like a hash ( # ).
Does anyone know what this is?
If anyone knows a more elegant way to do this, please advise. Here's what I have:
0+$|00+$|000+$|0000+$|.0000+$|0+\s|00+\s|000+\s|0000+\s|.0000+\s|0+\n|00+\n|000+\n|0000+\n |.0000+\n|0+\r|00+\r|000+\r|0000+\r|.0000+\r

See my answer in the Script forum: http://www.adobeforums.com/webx/.3bbf275d.59b4d546/0
(You shouldn't post a question twice.)

Similar Messages

  • How do I include the End of Paragraph character with the other characters in a GREP definition?

    I have a character style that changes the line spacing.  The GREP definition that applies it is a period.  This selects everything bu t the Endo of Paragrpah character (EOP).  The result is that the entire paragraph reformats but the last line of text has the wrong spacing.
    I am new to GREP and have not yet found a way to include the EOP character in the change.  I have tried  the statement :    .*$   but that has no affect.

    JES5910 wrote:
    Try defining a paragraph style with a smaller font and leading size then the default style and apply it to the pragraph using GREP definition of a period (all characters).
    That's exactly what I did. I started with 12/14 and changed to to a style using 8/9. Everything changed.
    There is no need to select all the text in a paragraph to assign a paragraph style since the style is aparagraph level attribute. You cannot have more than one paragraph style applied to a single paragraph, so it is IMPOSSIBLE that the end of paragraph marker has a different paragraph style applied than the rest of the paragraph. It IS possible, however, to apply a different character style or local formatting to it (and that's one reason it's better to use a triple-click instead of dragging to select an entire paragraph), so if the last line is not picking up the corrct spacing, the EOP character is either character styled or locally formatted.
    The only way you would know if this is the case is by selecting the EOP character, either as part of the entire paragraph, or by itself. If the paragraph style is then listed with a plus sign, there's local formatting applied. If not, check the character styles panel and I think you'll see a character style applied there (it would say mixed if you've selected the entire paragraph, unless of course you've applied the same character style to everything, which would be a major mistake).
    You can use GREP to remove the character style, if that's what it is, by searching for \r and in the change format set the character styel to [None]. This would work for all paragraphs regardless of waht the leading should be. If the incorrect specification is a local format, however, you would have to either select all text and remove local formatting (which might remove somethign you want, as well) or set up GREP searches to look for the \r with the correct paragraph style in the find formatting, then change the leading explicitly for that style inthe change formatting.

  • How to get consecutive numbering at the end of paragraphs?

    In a big text some paragraphs, already styled, need a consecutive numbering.
    At the beginning of the paragraph the numbering will create a mess.
    Tried with fake footnotes: Impossible. The text has footnotes and converting the faked ones to text is not available.
    Tried a nice script written by Jong to add/subtract a number on numbered items, but it is restricted to index situations.
    O R I G I N A L                                   R E Q U I R E D
    a. Many years ago.                    a. Many years ago. [1]
    Lucy Smith                              Lucy Smith
    b. Margaret run away.               b. Margaret run away. [2]

    Hi, Camilo:
    First of all,  I was not thinking clearly when I blamed ID for a cross-reference bug. It was my error. Cross-references within a document need to be updated by the author, using the Update cross-references button at the bottom of the Hyperlinks & Cross-References panel, when they're moved or their source content changes. I was thinking about the known issues with cross-references that go between ID document files, which update automatically - performance slows, and sometimes they cause crashes.
    Here's the replacement reply for my previous post #1:
    camilo umaña wrote:
    In a big text some paragraphs, already styled, need a consecutive numbering.
    At the beginning of the paragraph the numbering will create a mess.
    Tried with fake footnotes: Impossible. The text has footnotes and converting the faked ones to text is not available.
    Tried a nice script written by Jong to add/subtract a number on numbered items, but it is restricted to index situations.
    O R I G I N A L                                   R E Q U I R E D
    a. Many years ago.                    a. Many years ago. [1]
    Lucy Smith                              Lucy Smith
    b. Margaret run away.               b. Margaret run away. [2]
    It's not clear if the right-hand numbers are supposed to replace the left-hand numbers while keeping the same sequence, or if you want to retain the left-hand numbers. You can use cross-references to create right-hand numbers from the paragraphs auto-numbers.
    Insert a cross-reference to the paragraph at the end of the text, with a format that captures its autonumber, and adds any ornamentation, like the square brackets in your example.
    If the rightmost number must be positioned at the right margin of the numbered paragraph, no matter how long or short it is, or if it wraps around to new lines, add a right-aligned tab stop to the paragraph style, positioned at the location where you want the number to appear, and insert a tab character in the paragraph before the cross-reference.
    If the left hand numbers are supposed to go away, you can't change the paragraph style to a non-autonumbered style, because you need the numbers that the cross-references capture. So, you need to create a character style that's very small and uses Paper for the text color, to hide the autonumbers. If the smallest point size (IIRC, it's 2 points) leaves too much space at the left of the autonumber, you might be able to reduce it further by using a small value in the Horizontal Scale property of the Advanced Character Formats in the Character Style dialog box. Your example seems to show that the numbered paragraphs are indented, so the space occupied by the hidden autonumbers may not be a problem.
    If the paragraphs are rearranged in sequence, you'll need to use the Update Cross-References button at the bottom of the Hyperlinks & Cross-References panel to update the affected cross-references.
    I'm still not clear about numbers at the end of the paragraphs in square brackets. Are they supposed to be the same value as the auto-number at the beginning of the paragraph, except that they use a numeric display format instead of an alphabetic format?
    I don't know of any code that can work with a find/replace action that can capture a paragraph's autonumber and display it at a specific location. As you've seen, cross-references need to be inserted manually. You might post a query in the InDesign scripting forum to see if someone has figured this out. If there's no complete solution, you might want to ask about a script that searches for the ends of paragraphs of the autonumbered paragraph style and opens the Insert Cross-Reference dialog box.
    Using Quick Apply to execute the Insert Cross-References command, which opens the New Cross-References dialog box, might save some energy for doing the many manual cross-references insertions. Search Google for terms like "InDesign quick apply" without quotes. You can open Quick Apply with a keystroke shortcut - Cmd+Return on Mac. You can type abbreviated commands. I use "rt cr" without quotes for (Inse)rt cr(oss-reference). Opening Quick Apply repeats the last command that was entered.
    Also, if you haven't tried a Google search for phrases like "InDesign numbered list at right end of paragraph," without quotes, give it a try. There are lots of links, including one to this forum article. Perhaps there's a golden nugget among them.
    If you think it's important for ID to be able to place autonumbers at the ends of paragraphs, please post a formal feature request here: Wishform Eventually, some user originated feature requests are incorporated in future ID releases.
    HTH
    Regards,
    Peter
    Peter Gold
    KnowHow ProServices

  • Search for end-of-paragraph before end of story? CS6

    Hi,
    Does anybody know of a way to search for a paragraph mark directly
    before an end of story marker? I'd like to get rid of them, e.g., in
    footnotes, where the last paragraph mark causes an unnecessary blank line.
    Thanks,
    Ariel

    I found \z on Mike Witherell's great little chart at http://www.jetsetcom.net/useful-resources/indesign-cs6-resources.html
    End of paragraph, at least in GREP is a location, not a character (the metacharacter is $) and can't be selected or replaced. Every paragraph has one. Paragraphs before the end of story also have a paragaph break, and that's what you are trying to remove at the end of your footnote story.
    @David, Why bother withthe lookahead? \z is the location, so I would presume that the search would start at the end of story and look at the last character. That has to be faster than parsing every break in the paragraph to check for the end of story location after, and there's no possibility that you will actually delete the EOS since it can't actually be selected.

  • I want to set up a roaming network. I have directions. I have an extreme set up and working.  I need to add an express.   When I open airport utility I get the internet pic of internet and the base station.  How do a get to the setting screens?

    Directions require that I change settings on the base station on the screen that interent connection, TCP/IP DHCP NAT how do I get to that screen through airport utility.
    Then I need to for my express to get to the screen the screen for wireless.
    This has changed since last time I did this.
    How do I get to the screens.

    Your existing Extreme might already be configured in Bridge Mode. As long as the Extreme is working now, do not change any settings on the Extreme.
    Apple incorrectly assumes that all users are connecting to a simple modem when most users are connecting to gateway devices....combination modem/routers. 
    You probably are as well and Bridge Mode would be the correct setting when connecting to that type of device.

  • Do I need to have Airport Express to connect to other computers on our homer network?

    Do I need to have Airport Express to connect to other computers on our homer network?

    Not necessarily. You could use the "Create Network" feature of your MBP's built-in AirPort card to provide an Ad-hoc wireless network for local wireless-capable computers to connect to.

  • End of paragraph

    Hi ,
    I m facing problem in finding end of paragraph in text file through java like we do to find the end of file Using EOF like wise i want to find out the end of paragraph.
    Do u have any solutions for this.

    think about what would idenitfy the end of a paragraph
    think about how to read the file
    rinse and repeat
    heres a hint -
    if a new paragraph starts another one most likely just ended.

  • How do I change the spacing before or after a hard return in Pages 5.5.2?    I am working on an academic article and need to specify paragraph formatting (OS X Yosemite 10.10.2)

    How do I change the spacing before or after a hard return in Pages 5.5.2?    I am working on an academic article and need to specify paragraph formatting (OS X Yosemite 10.10.2)

    Hi Michele,
    Select the paragraphs where you want to change the spacing.
    Format Panel > Text > Spacing
    You can change 1.0 - Single to something else, or type a number in Before or After.
    Regards,
    Ian.

  • Trying to use iCloud email on my pc - do I need to buy Outlook Express?

    I have an iPad and iPhone, but have kept my PC.  Converting to iCloud for my mail.  Do I need to buy Outlook Express to use iCloud email on my PC?

    iCloud email will work with almost any email client.  Use whatever email client you have on your computer now and set up your account using these settings: http://support.apple.com/kb/HT4864.

  • Insert End of Paragraph mark before any superscript number

    I am formatting a Bible for a client. The text was provided with verse numbers before each verse, but each chapter is one long paragraph. Now the client has decided they want each verse to begin a new paragraph. How can I globally insert an End of Paragraph mark before each superscrpt verse number?

    In case it helps, and for what it's worth, here's what I assumed:
    As in many bibles, the superscript verse number is simply mixed in the text, preceeding the first sentence of the verse. Could be anywhere, and there is no other special treatment involved. Like this:

  • Need help regarding Arithmetic Expressions

    Hi Experts,
    I have a requirement where in I need to pass Arithmetic Expressions (+,-,/) as constants to a subroutine.For ex:
    constants:c_p   type char1 value '+',
                     c_m   type char1 value '-',
    data:v_a type char1 value '2',
             v_b type char1 value '6',
            v_r    type string.
    v_r = v_ a   + v_b.
    In the above instead of + I want use c_p.Please help me out is there any other way in defining Arithmetic expresiions where I could use constants or variables instead of directly using these expressions(+,-).Thanks in advance.
    With Regards,
    Srini..

    Hello Srini,
    I think you must have a look at the FMs belonging to FuGr. CALC.
    For e.g.,  EVAL_FORMULA which evaluates Literal or Variable formulas
    CONSTANTS:
    C_P TYPE CHAR1 VALUE '+',
    C_M TYPE CHAR1 VALUE '-'.
    DATA:
    V_A TYPE CHAR1 VALUE '2',
    V_B TYPE CHAR1 VALUE '6',
    V_FORMULA TYPE STRING,
    V_RES_F   TYPE F,
    V_RES_P   TYPE P.
    CONCATENATE V_A C_P V_B INTO V_FORMULA SEPARATED BY SPACE.
    CALL FUNCTION 'EVAL_FORMULA'
      EXPORTING
        FORMULA                 = V_FORMULA
      IMPORTING
        VALUE                   = V_RES_F
      EXCEPTIONS
        DIVISION_BY_ZERO        = 1
        EXP_ERROR               = 2
        FORMULA_TABLE_NOT_VALID = 3
        INVALID_EXPRESSION      = 4
        INVALID_VALUE           = 5
        LOG_ERROR               = 6
        PARAMETER_ERROR         = 7
        SQRT_ERROR              = 8
        UNITS_NOT_VALID         = 9
        MISSING_PARAMETER       = 10
        OTHERS                  = 11.
    IF SY-SUBRC = 0.
      MOVE V_RES_F TO V_RES_P.
      WRITE: V_RES_P .
    ENDIF.
    BR,
    Suhas

  • [svn:bz-trunk] 10029: Revert change 9940 for BLZ-429 which broke circular references, need to take another look.

    Revision: 10029
    Author:   [email protected]
    Date:     2009-09-04 11:57:34 -0700 (Fri, 04 Sep 2009)
    Log Message:
    Revert change 9940 for BLZ-429 which broke circular references, need to take another look.
    Ticket Links:
        http://bugs.adobe.com/jira/browse/BLZ-429
    Modified Paths:
        blazeds/trunk/modules/core/src/flex/messaging/io/amf/AbstractAmfInput.java
        blazeds/trunk/modules/core/src/flex/messaging/io/amf/Amf0Input.java
        blazeds/trunk/modules/core/src/flex/messaging/io/amf/Amf3Input.java

  • HT1515 which version of Airport Utility is needed for my Airport Express A1084????

    How can I find out which version of Airport Utility is needed for my Airport Express A1084????

    I have this issue, too. The problem with the advice from Saito_Chickara is that Mavericks (I'm on 10.9.2) does not allow you to run AirPort Utility 5.x. So for those of us on Mavericks, what can we do? I have yet to find a solution. This is really frustrating.

  • GREP remove white space at start and end of paragraph

    Hi,
    Question for the GREP experts: I'd like to construct a GREP expression
    that will remove all white space at the start AND end of a paragraph in
    one go.
    What I've got so far works, but you have to run it twice to work:
    I'll try and post it at the bottom of this message, but since I'm
    posting via email it probably will come out scrambled, so I'll describe
    what I've got so far:
    Two expressions in parenthesis separated by the OR character (pipe). The
    first expression searches for one or more space, tab or white-space at
    the beginning of a paragraph.
    The second expression searches for the same at the end of the paragraph.
    Each expression is in parenthesis, and the two groups are separated, as
    I say, by an OR sign.
    However, this has to be run twice for it to work. For it removes all the
    spaces at the start of paragraphs, then when run again all the spaces at
    the end.
    Any ideas how to get it to work in one go?
    Thanks,
    Ariel
    The expression is:
    (^[ \ts]+)|([ \ts)+$)

    Arïel, your GREP appears a bit mashed up in the forum -- was it something like this?
    (^[\t\s]+)|([\t\s]+$)
    If so:
    1. "\s" is "any whitespace", so you would not need to include "\t" as well. But I would not recommend this, as a HUGE disadvantage of "\s" is it also includes hard and soft returns: double returns are seen as "any whitespace" (the first return) and then "end of line" (the second return), and the first is removed. ("Disadvantage" is subject to what you want to accomplish, by the way. I usually don't want this so I list each possible whitespace character that may be removed.)
    2. The parentheses around each 'section' of this GREP are not necessary. The OR operator is 'highest level' -- in this case, since you have an entire left part OR an entire right part, you can omit all parentheses.
    3. This works for me ...
    ^[\t ]+|[\t ]+$
    ... and despite Peter's not-too-shabby suggestion, I would still recommend using mine instead. It's easier on ID (since it only has to remove text, not "remove-and-then-insert-again" (which is exactly what using the $.. operators do), and, more importantly, there are limits to what $1 can 'pick up'. I can't recall the special circumstances, but I have had text attributes shift, and footnotes and anchored objects disappear/being mucked up/otherwise mangled.

  • GREP to Add a Carriage Return at End of Paragraph

    The following search criteria adds a return at the beginning of a paragraph
    Find
    ^.
    Change to:
    ~b$0
    Now I want to instad add a carriage return at the end of the paragraph instead, so I changed my search criteria as shown below, but never get the carriage return. How do I add a carriage return to the end of a pararagh?
    Find
    \z
    Change to:
    ~b

    Peter
    Thanks for your help. I want to create a new, empty paragraph so I can apply a different paragraph style to it than the paragraph style used in the preceding paragraph. Once I have that, I will cut and paste text into the new paragraph that uses the just applied paragraph style.
    Or perhaps more simply, move text that already has a paragraph style applied  to it into a new location, but first have that new location set up with the correct paragraph style so that the formatting is not lost.
    Hope that makes sense.

Maybe you are looking for

  • How to use R & R to backup to an external USB HDD?

    Greetings, I have two Lenovo Workstations and one is Desktop and other is Thinkpad and I would like to have it backed up to a single 1TB External HD and I cannot seems to backup both of them on single External HD. It seems that it does not work with

  • Thumbnails enlarge when hovered over

    Hi all, I'm trying to create an archive page for the past issues of a newsletter. I've tried creating one with CSS, which looks fine in Firefox but tweaks out in IE6. So I'm trying to create an archive page using Flash. I'd like to create a page simi

  • IMac G4 Booting Problem

    After 6 years of trouble-free service, my iMac (17" G4, 1.25 Ghz) won't boot past the gray screen with the apple and the spinning ball. It was running on 10.5.8. I've tried everything I could find in the Apple troubleshooting articles, including rese

  • Saving user input for later use ! How ?

    Hi ! I wrote a simple program called GPA Calculator. In the program, the user chooses the lessons he takes and he enters his grades on those lessons and the computer calculates his GPA. It was a simple task to do thanks to swing class. But the proble

  • Mail Crashing Randomly

    Hi. I upgraded my mac with ssd and crashing problems started. There's crash report for mail. Note: I install maverics and transfered my files with wizard. Process:         Mail [4056] Path:            /Applications/Mail.app/Contents/MacOS/Mail Identi