Number of words - ignore the numbers and symbols

Hi guys,.

can someone tell me how to ignore the numbers and symbols by adjusting the script below, that is, just count the letters in an entire document.


myDoc = app.activeDocument

h = 0

for (var j = 0; myDoc.stories.length > j; j ++) {}

h = myDoc.stories [j].words.length + h

}

Alert ("You have" + h + "words in this document")

See you soon,.

Samuel

In CS3 and later versions, you can use this:

app.findGrepPreferences = null;
app.findGrepPreferences.findWhat = "[\\u\\l][-\\u\\l]+";].
found = app.documents [0] .findGrep ();
Alert ("You have" + found.length + "words in this document.")

A "word" is defined here as any string of uppercase and lowercase letters and hyphens. It's perhaps too strict, but you can change the GREP to meet your needs.

Peter

Tags: InDesign

Similar Questions

  • select lines with garbage (not the numbers and point symbols)

    Hi all! I've got varchar2 column where users insert what they want. But this column is used for the value of numbers (from 0.00 to 100.00). How can I select only the number and the symbol dot:

    NVL (ABS (regexp_replace (Replace(Avalue,',','.'),'[^ 1, 2, 3, 4, 5, 6, 7, 8, 9, 0,.,]')), 0)

    Now, I need to select lines with symbols of the trash to correct errors. How do I "invert selection"? I mean by selecting only the lines that are composed of waste (except the numbers and the dot symbol).
    Thanks in advance.

    You can try this

    select trim(translate(replace(avalue,',','.'),'1234567890.','           ')) from dual
    

    If the symbols of the trash will be inserted then it will return that

  • When documents come on Notepad, they're just numbers and symbols. How can I get a normal display of documents?

    When I open the documents to view or print emails or Web sites, they appear on the notebook.  However, they have encrypted air (numbers and symbols).  How can I get a normal display of documents so I can print them?

    What type of files you are trying to view?

    If you try to view a file not that plain text, such as a .doc or .rtf file, you must use Wordpad instead.

  • numbers and symbols do not work online

    I've upgraded to Vista XP and now the last row of numbers and symbols will not work online.  Same result with 2 keyboards.  It is impossibe to connect to an account using an email address.  This happens in IE 7, 8, 10 and 11 also with Google Chrome.  The numbers and the symbols work fine in another application

    Before the upgrade to Vista everything worked well.  There must be a known issue with Vista for this catch - up.

    If another keyboard displays the same behavior, this can often be traced back to the identity theft protection software that encrypts your keystrokes such as those provided by AOL or Comcast (e.g. DataMask, constant guard or GuardID). If you have installed the encryption of typing software, I can't recommend disabling/uninstalling software or specific assistance in support of the software publisher's web site.

  • Ignore the error and continue the pl/sql block

    Dear all,

    Please help me to fix the script below.

    I had an obligation to write a pl/sql that will handle the update instructions.

    For example:
    A table that contains 10 rows of data. Through pl/SQL block, I update the 10 rows (or a smaller number of lines).
    Now, the scenario is by updating registration / line 4, oracle has met an error and then oracle leave pl/sql block and cancel the transaction.

    My requirement here is, by updating the records, if oracle encounters an error, it must raise an error or ignore the record and continue to process records. Oracle wouldn't pl/sql block.

    We are using oracle 10g.

    Thank you
    KODS

    As has already been suggested, you might check DML ERROR LOGGING

  • have the icon to download helper with video up, I have until it clicks, dosnt download or convert a number appears next to the icon and its listed in the queue draft.exe

    I was able to load videos 26 then he stopped down. I checked the preferences, the version is 4.9.24, I can see that the video is listed next to the icon, when I drag the mouse over it.

    I support download icon, when the video is running. I click next to the icon and choose the game I want, on fast download I see it loads, but no dwhelper. dosnt download or convert a number appears next to the icon and its listed in the queue draft.exe

    There is a problem with DownloadHelper Firefox 36. They are working on a new version, you can download and help test this discussion page:

    https://groups.Google.com/Forum/#! Forum/video-video downloadhelper-5

  • the text and symbols are too small in photoshop cc, I have a screen high resolution (IPS), what I can do. Now, it is difficult to read

    the text and symbols are too small in photoshop cc, I have a screen high resolution (IPS), what I can do. Now, it is difficult to read

    Install CC 2014 and turn on the preference scale of 200% user interface.

  • How to record the numbers and words in the same file

    Hello:

    I did a vi where I record the spectrum and its integration in different positions of a two-dimensional net. I save the information in two spreadsheet with the comand "write to file measure."

    Now, I am recording the parameters initial positions, end X X and space between measurement points. I want a file with two columns that looks like:

    Initial position X 1000

    final position X 2000

    space 100

    But idon't know how to save the words and numbers in the same file.

    As I have to perform several steps I want to automatically choose the name of the file (something like parameters_1, parameters_2...)

    Thank you for your attention

    Hi bitxor.

    You can use all the functions of the WriteTotext file to write strings to a file.

    Then you could set up WriteToMeasurementFile' to add new data to existing files (instead of overwrite or renaming)...

    BTW. It is not a good idea to mix lvm files containing arbitrary spreadsheet data!

  • Which is more accurate: number of words in the Javascript or copy/paste in Word?

    In providing Word manual counts, that I'm working, I noticed that by using a JavaScript in Acrobat gives me a number that differs from the one I get when I copy the text in the PDF file and paste it into MS Word. Which is more accurate?

    Thank you.

    No doubt Word. JavaScript in Acrobat can consider each point online

    Do the points to be a Word.

    It is possible to ignore them, but you will need a more sophisticated code.

    What code you are using, anyway?

  • Import a Word file, the numbers do not continue after an image

    We import large Word files that are full of paintings step/Action with pictures that separate tables. Here is the output of another tool files. RH5 that importation of tables and numbers are hard coded - they are not the numbers of HR, but are all there.

    In the first RH7 table has a 1 in the step column and it is numbered article HR. The table has 2 rows - a header and a single line stage. An image of the screen is displayed below. Then the table 2nd step/Action.

    In the 2nd table... and all the tables below the 'Step' column is empty in the line where the number should appear. The header is fine. All of the text in the title of the Action is very good. But the number of step is missing.

    These files have anywhere from 20-100 + steps. It is a major issue for us. Anyone have any suggestions on how to fix/change? For the moment, we are hand numbering... not everything simply will not work as a long-term solution.

    All suggestions are accepted with gratitude!

    Peter solved this problem! The answer is to save the file in Word as 'filtered Web page. " This apparently changes the auto-numeros in hard-coded numbers and they import perfectly. BLESS, PETER! I imagine that there are other "gifts" of the Word who may benefit from this solution, so it is very good to know.

    As always, the Forum has saved my butt and you all true experts out there... know we moderate authors appreciate your time, energy, expertise and willingness to share it all! Without you we would be absolutely dead in the water.

    Save as Web page, filtered. What a solution! Take care...

  • number of words in the display of 0 pages?

    I just started using Pages: he's literally my first paper! (running 5.6.1) I left a MacBookPro with complete Office Suite on a MacBook Air and decided to try pages, number, Apple Mail etc as an alternative to the office of re-purchase with Word, Excel and Outlook.  I found where to put the number of words floating window to the top, but it is resolutely show 0.  I tried to save, close and reopen the document. copy of Notes mode in Document mode. highlighted text, but there is zero.  This is one of my key functional requirements!  Please?  I can't see someone else with a similar problem on the forum. Thank you

    It is a word processing document?

    Pages do not count words in objects such as text boxes, shapes, tables etc.

    Peter

  • When you try to add the option "number of words" for the column headings in the window my documents, the number of words doesn't quite show

    For school, I need to take a screenshot of the header of column of count of Word showing under my documents.
    When I added the option to account for Word for column headers and clicked it twice so that the word count
    show for files listed, nothing shows up.

    Any help with this would be greatly appreciated!

    Hello

    Welcome to the Microsoft Community and thanks for posting the question.

    According to the description, you are having problems with the number of words not displaying do not.

    What is the format of the Document?

    Number of words is a feature that is available only for Documents Word from Microsoft.

    http://Office.Microsoft.com/en-in/Word-Help/count-the-number-of-words-in-a-document-HA010368775.aspx

    Meet us if you encounter problems with the number of words or any other issue of Windows, and we would be happy to help you.

    Good day!

    Hope this information helps.

  • How to find the numbers and make it more 1

    Hello world

    I want to find a group of numbers in my selection, and then do it + 1

    for example:

    elderly (\d\d)

    I want to do is + 1

    and

    201 (\d)

    I want to do is + 1

    What is the syntax?

    Thank you

    VK

    Hi, VK,.

    Try this. It looks up the number in the selection and added, for example, finds it "(20) years", "201 (2)" and will replace it for "elderly (21)", 201 3 respectively.

    var _selection = app.selection[0];
    app.findGrepPreferences = changeGrepPreferences = null;
    app.findGrepPreferences.findWhat = "(aged) (\\(\\d\\d\\))";
    var found = app.selection[0].findGrep();
    for(var i=0;i
    

    Kind regards

    Cognet

  • Wonder about the difference between the element and symbol with draggable drag

    I'm trying to understand the difference between a symbol and a with draggable element.

    She is the example I did: https://www.box.com/s/v2s8ueeqof9litu4zvwm

    • for the Rectangle element, drag works very well. The item dragged from where he is.
    • the symbol of the box which is initially 0 left and top 0, no problem
    • the symbol of the boxCopy which is placed on the left 100 and top 100, on the trail, he jumps to this amount.

    I guess drag Gets the original position of the symbol on the stage box and add these numbers to the position of the step. I have the symbol arround medication and it seems that the scene is translated left and top of the amount of the left and top of the symbol.

    This does not happen with the Rectangle element.

    Obviously there is something I don't understand.

    Ok. Joel gave me the solution.

    After you have placed your symbols on the stage, remove the left and top lines in the symbol. This will reset to (0,0).

    Here is the corrected file. In the left panel, you will see that there is no left and top except one to show the difference.

    https://www.box.com/s/v2s8ueeqof9litu4zvwm

  • Helps the numbering and bullets

    Hello

    I have a paragraph style that uses numbering, it is called the newspaper. When I apply a paragraph of subtitle style, I want to have balls that take this title number and add a point (.) and then the sequence numbers after that. See the example.

    1. dogs (paragraph title style)

    1.1 reproduces (style subtitle would take the number of title and add a point (.) and then the numbering in order after that)

    1.2 colors (style subtitle would take the number of title and add a point (.) and then the numbering in order after that)

    1.3 etc etc etc (style subtitle would take the number of title and add a point (.) and then the numbering in order after that)

    2 cats (paragraph title style)

    2.1 reproduces (style subtitle would take the number of title and add a point (.) and then the numbering in order after that)

    2.2 colors (style subtitle would take the number of title and add a point (.) and then the numbering in order after that)

    2.3 etc etc etc (style subtitle would take the number of title and add a point (.) and then the numbering in order after that)

    3 rabbits (paragraph title style)

    3.1 breeds (style subtitle would take the number of title and add a point (.) and then the numbering in order after that)

    3.2 colors (style subtitle would take the number of title and add a point (.) and then the numbering in order after that)

    3.3 etc etc etc (style subtitle would take the number of title and add a point (.) and then the numbering in order after that)

    I've tried a few things, but nothing works... someone can help me understand this?

    Thank you!

    Babs

    Note the characters used in the dialog boxes.

Maybe you are looking for

  • Pavilion g7: HP market/Admin password

    I haven't used my computer for awhile, and I forgot the password of Admin/Power-on Password. The disabled system error number is 64152385. It is a g7 Pavalion. Help, please!

  • Compac CQ5115UK Realtek onboard sound.

    I have Cambridge SoundWorks Digital Surround decoder amplifier, with my old Sony computer and a soundcard Audigy2 sound effect surround was excellent. With my Compac CQ5115UK and Realtek, sound sound surround even now is poor breeding. The CQ5115UK c

  • How do I create a new folder in iCloud by using my iPad?

    How can I create a new folder to iCloud for my iPad? I can create a new folder to iCloud if I login to iCloud via Safari on my iMac or a MacBook. However when I use Safari on my iPad, I receive a 'Welcome screen' tthat is useless because it does not

  • Update of movement causing problems

    I developed a Machine Vision system that has worked more than 10 years without any problem of movement. I recently upgraded to Windows XP to Win7 computer; LabVIEW 7.1 to 2013; TestStand 4.2 to 2013; OR-Motion of 7.7 to 8.5.1. Initially, the system s

  • T500 initialize the W10 64-bit problem

    I have a rather strange problem. Basically if I fresh start my T500, aka show etc. of a complete power off, the splash screen, but the display never passes the actual Windows OS 10. I can say the system is running and if I manually set the system sle