-1

1

Keep getting a module error here, though I created the module

rioV8
  • 24,506
  • 3
  • 32
  • 49
  • 1
    To help better answer a question, you need to provide code/config snippets you tried, errors you got, and docs you looked up. Please consider improving your question. The question ideally should include a summary of the work you've done so far to solve the problem, and a description of the difficulty you are having solving it. – Samisa Jun 07 '21 at 01:03
  • See [Why not upload images of code/errors when asking a question?](https://meta.stackoverflow.com/questions/285551/why-not-upload-images-of-code-errors-when-asking-a-question) for reasons **not** to do it. – martineau Jun 07 '21 at 02:25
  • Is the module in the same directory as your python file – PCM Jun 07 '21 at 06:00

2 Answers2

0

Create a file named literally __init__.py in the same directory; see duplicate What is __init__.py for?

ti7
  • 16,375
  • 6
  • 40
  • 68
0

Add these codes to the ping.py file before you import the moving_ping:

import sys
sys.path.append("C:\Users\ssand\OneDrive\Desktop")

If it does not work remember to add an empty __init__.py file under the C:\Users\ssand\OneDrive\Desktop\PingPong folder.

Steven-MSFT
  • 7,438
  • 1
  • 5
  • 13