I have a Python script that contains the following modules:
from tkinter import *
from tkinter import ttk
from tkinter import filedialog
When I run the code in IDLE by pressing F5 the script runs fine and starts my app.
However, when I go to the command prompt and type
python ScannerApp.py
I get the following error:
File "tkinterTest.py", line 1, in <module>
from tkinter import *
ImportError: No module named tkinter
How do I get rid of this error? The ultimate goal being to make this script into a .exe.
One thought is that python is not added to my environmental variables under Path, it is added as it's own variable. Could that be causing the issue?
My question does not pertain to the difference between Tkinter and tkinter. My question was about why when I ran code through the command line I was getting an error. The issue happened to be that my environmental variable python was set to run python 2.7 instead of the necessary python 3.6 (which uses tkinter).