+ Reply to Thread
Results 1 to 3 of 3

Word wilcard replace help needed.

Hybrid View

  1. #1
    Registered User
    Join Date
    11-13-2009
    Location
    London
    MS-Off Ver
    Word 2003
    Posts
    1

    Word wilcard replace help needed.

    Hi, I'm looking for some help.

    I'm unsure if this is possible but I have a large document that needs some work doing to it. Due to the document having been converted from another format, there are a lot of paragraph breaks mid sentence which I have tried to rectify using Word's find and replace. First I have converted the paragraph's to manual page breaks then, using wildcards, I am currently trying to fix the breaks going on the assumption that the break would be followed by a lower case letter as opposed to an upper case with a normal paragraph break, I am doing this so the wildcard search will differentiate between the two. The wildcard seach I am using is:-

    ^l[a-z]

    Now this finds every one of the unwanted breaks fine but how can I make sure the first character of the discovered wildcard word is replaced correctly after the space? Currently the first letter of the first word is being cut, obviously due to this being part of the wildcard search.

    Thanks in advance, I'm no expert in this and hope someone might be able to help.

  2. #2
    Forum Expert pike's Avatar
    Join Date
    12-11-2005
    Location
    Alstonville, Australia
    MS-Off Ver
    2016
    Posts
    5,342

    Re: Word wilcard replace help needed.

    try ..
    ^\s([a-z])
    If the solution helped please donate to RSPCA

    Site worth visiting: Rabbitohs

  3. #3
    Forum Expert pike's Avatar
    Join Date
    12-11-2005
    Location
    Alstonville, Australia
    MS-Off Ver
    2016
    Posts
    5,342

    Re: Word wilcard replace help needed.

    or add
     strReplace = "*$1"
            
               str = .Replace(str, strReplace)

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1