Count Lines of Word Document

maheshmahesh Member Posts: 115
Hello Nav Experts,

I want to count lines of word document by Automation variable.

To count Characters, syntex is: wrdDoc.Characters.Count;
To count words, syntex is: wrdDoc.Words.Count;
would anybody tell me the syntex of counting\finding lines?

Even if you can guide me finding a "New Line" character in word document then also it would be great.
Best Regards,
Mahesh Jain
mahesh@reliconservices.com

Comments

  • MacGyverMacGyver Member Posts: 7
    wrdDoc.Lines.Count
  • maheshmahesh Member Posts: 115
    Is it your guess work?
    There isn't anything like "wrdDoc.Lines.Count". Please type in CAL & it would give you error.

    Mahesh Jain
    Best Regards,
    Mahesh Jain
    mahesh@reliconservices.com
  • MacGyverMacGyver Member Posts: 7
    what automation server are you using? That code works with "Microsoft Word 12.0 Object Library" Automation Server. :thumbsup:
Sign In or Register to comment.