In a Ruby web application, I want users to be able to upload documents. If the user downloads a Microsoft Word file (.doc), I want Ruby to count the number of pages in the file. It would be even easier to use the word count, but the page count will do.
How can I do it? Is there a Ruby library / gem that can do this for me? Is this even possible with the DOC format?
source
share