Python Forum
getting an import statement to work in my program
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
getting an import statement to work in my program
#1
I have installed PyCharm as my python IDE.

Previously, I (think) I installed a module pygame that has USB joystick interfaces.

In my program,I want to insert the import statement but am having errors.

I have inserted import pygame and get a module not found error.
so, I know the directory where pygame was installed.. C:/users/barry

so I am trying import C:/users/barry and this doesn't work.

What am I doing wrong??
I have tried c\users\barry\pygame.py and a few other attempts so how do I get pygame imported?

Thanks
Reply


Messages In This Thread
getting an import statement to work in my program - by barryjo - Dec-06-2021, 03:56 PM

Possibly Related Threads…
Thread Author Replies Views Last Post
  Can't get a new program to work jpotter0 2 1,027 Nov-28-2022, 03:40 AM
Last Post: jpotter0
  Cryptic Error with import statement Led_Zeppelin 2 2,604 Jan-11-2022, 01:13 PM
Last Post: Led_Zeppelin
  Why doesn't this print statement work? stylingpat 10 5,862 Mar-23-2021, 07:54 PM
Last Post: buran
  import statement in a virtual environment leodavinci1990 1 2,403 Mar-04-2021, 12:57 AM
Last Post: snippsat
  Does "import xlrd" work in Thonny? cnutakor 3 3,050 Apr-30-2020, 12:41 AM
Last Post: Larz60+
  import scalalib package doesn't work manu_brighter 2 2,943 Apr-17-2020, 06:36 PM
Last Post: snippsat
  return statement will not work TheTechRobo 2 2,670 Mar-30-2020, 06:22 PM
Last Post: TheTechRobo
  [split] import PIL dont work vedansh 1 2,114 Mar-29-2020, 10:00 AM
Last Post: Larz60+
  Newbie to Python Why does this if statement not work? Wrightys99 5 2,650 Mar-26-2020, 12:04 PM
Last Post: buran
  import PIL dont work rodink 14 13,122 Feb-22-2020, 08:48 PM
Last Post: snippsat

Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020