var docParCount = app.documents.everyItem().stories.everyItem().paragraphs.length; // paragraphs
... count the paragraphs.
But in Indesign (F8) we can see the character count, word, paragraph... but only counts paragraphs with text, no line breaks without text. How I can get this with a script?
@Marcos – be aware, that with your line of code in your question you'll never get to footnotes or tables in stories or nested tables in tables or tables in footnotes…
I really think the best way for scripting that would be a GREP search. If it's too slow, I fear you have to write a C++ plugin.
Europe, Middle East and Africa