If we consider that the entire Python application has only this much code: (im using: pytwain library for documents canning)
import twain
sm = twain.SourceManager(0)
src = sm.open_source()
When I run the application it works as it should display the Data Source Manager with my virtual scanner. (also works with real scanners)
But when I create an .exe file with pyinstaller, it loads the dialog but doesn’t find the virtual scanner.
Why does this happen and how can I solve it?
I tried a lot of things. But its not workung. DSM is empty.
But if I run the apllication with: python app.py its showing sources.
Petar Beric is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.