0

I am trying to make a program that could automatically scan the images or texts on a user's desktop and then convert it to a .txt file for text analysis.

So far I have found source codes to convert PDF and HTML into .txt. However I would like to make my program automatically scan the desktop screen at certain time intervals rather than manually inputting the source such as:

$pdf2txt.py samples/simple1.pdf

I don't know where to start so any suggestion will be appreciated.

Pooya
  • 6,083
  • 3
  • 23
  • 43
Kirsteen Ng
  • 111
  • 1
  • 8

1 Answers1

0

First of all, the desktop is just a location in the file directory like:

C:\Users\Kirsteen\Desktop

So the next step would be to search through this directory for the types of files you are interested in. You'd be aiming to generate a list of valid file names that need to be converted. This Q/A might help you.

Once the files have been found run those converting scripts you have. To repeat this automatically put all of this in a loop and add a delay so that it runs once an hour/week.

To tidy things up, think about running this process in the background and making sure the program doesn't convert the files more than once if they haven't changed.

Community
  • 1
  • 1
Red Shift
  • 1,312
  • 2
  • 17
  • 29