I tried installing pyautogui in Visual Studio but whenever I run the following program:
import subprocess import pyautogui #pylint: disable=E0401 import time import pandas as pd #pylint: disable=E0401 from datetime import datetime def sign_in(meetingid, pswd): # Opens up zoom app subprocess.call(r"C:UserskrishAppDataRoamingMicrosoftWindowsStart MenuProgramsZoom") sign_in('6931145146', 'SKS123')
I get the following error:
File "c:UserskrishDesktopAUTOBOTZoom Auto Attender", line 2, in <module> import pyautogui #pylint: disable=E0401 ModuleNotFoundError: No module named 'pyautogui'
I tried the available solution import error for pyautogui
But it doesn’t work, So please help.
Advertisement
Answer
According to your description, please refer to the following:
Please use the command “
python --version
” or “pip --version
” in the VS Code terminal to check whether the python currently used by the VS Code terminal is consistent with the one displayed in the lower left corner of the VS Code.(If they are inconsistent, please use the shortcut key Ctrl+Shift+` to open a new VS Code terminal, it will automatically enter the selected environment.)
Check the installation of the module. (
pip show pyautogui
)The location where VS Code recognizes the python module is in “
Libsite-packages
” of the currently used python environment.
Run:
Reference: Python environments in VS Code.