+ Reply to Thread
Results 1 to 5 of 5

MS Word - Macro that counts the number of "~" between two specific values

  1. #1
    Registered User
    Join Date
    11-12-2012
    Location
    San Dieg, CA
    MS-Off Ver
    Excel 2010
    Posts
    6

    MS Word - Macro that counts the number of "~" between two specific values

    Hi All -

    I could really use some help!

    I have multiple files comprised of many smaller files. To identify the size of the smaller files, I have to count the number of "~" between two specific header segments. I have tried using the Find/Replace option. Currently, I am parsing the Word document by inserting a hard line return for each ~ and then copying the file to excel and completing the line count there - but that is becoming more difficult as I pass this process off to someone else.

    Any help would be greatly appreciated!!!

    Lesley
    Last edited by llfinney; 10-14-2013 at 07:07 PM.

  2. #2
    Forum Guru
    Join Date
    03-02-2006
    Location
    Los Angeles, Ca
    MS-Off Ver
    WinXP/MSO2007;Win10/MSO2016
    Posts
    12,920

    Re: MS Word - Macro that counts the number of "~" between two specific values

    To attach a sample doc file
    [*]Click Advanced (next to quick post), [*]Scroll down until you see "Manage Attachments", [*]Click that then select "add files" (top right corner). [*]Click "Select Files" find your file, click "open" click "upload" [*][*]Once the upload is completed the file name will appear below the input boxes in this window. [*]Click "Done" at bottom right to close the Attachment Manager.[*]Click "Submit Reply"[/LIST]
    Ben Van Johnson

  3. #3
    Registered User
    Join Date
    11-12-2012
    Location
    San Dieg, CA
    MS-Off Ver
    Excel 2010
    Posts
    6

    Re: MS Word - Macro that counts the number of "~" between two specific values

    5010835B.txt

    What I am trying to get is the count of "~" between ST* and SE*.

    Does that help?

    Thanks -
    LF

  4. #4
    Forum Expert macropod's Avatar
    Join Date
    12-22-2011
    Location
    Canberra, Australia
    MS-Off Ver
    Word, Excel & Powerpoint 2003 & 2010
    Posts
    3,832

    Re: MS Word - Macro that counts the number of "~" between two specific values

    Try:
    Please Login or Register  to view this content.
    Cheers,
    Paul Edstein
    [Fmr MS MVP - Word]

  5. #5
    Registered User
    Join Date
    11-12-2012
    Location
    San Dieg, CA
    MS-Off Ver
    Excel 2010
    Posts
    6

    Re: MS Word - Macro that counts the number of "~" between two specific values

    I tweaked this a tiny bit and it works perfectly! Thank you so much for your help.

    LF

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. Macro - Place number & color when find word "inactieve"
    By Jessy142 in forum Excel Programming / VBA / Macros
    Replies: 9
    Last Post: 09-26-2012, 10:54 AM
  2. [SOLVED] How to Count number of "Error" and "OK" after the word "Instrument" found in table row
    By eltonlaw in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 05-17-2012, 06:26 AM
  3. macro required for replaceing specific alphabat with number (like replace "A" with 9)
    By hutton448 in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 05-06-2012, 12:36 PM
  4. [SOLVED] Re: macro for converting number stored as "text" (or preceeded with ') to "number" formatting
    By markx in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 06-30-2006, 07:14 AM
  5. Replies: 1
    Last Post: 06-23-2006, 10:20 AM

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