On Tuesday, February 10, 2015 at 3:38:12 PM UTC-8, vlya...@gmail.com wrote: > I defined function Fatalln in "mydef.py" and it works fine if i call it from > "mydef.py", but when i try to call it from "test.py" in the same folder: > import mydef > ... > Fatalln "my test" > i have NameError: name 'Fatalln' is not defined > I also tried include('mydef.py') with the same result... > What is the right syntax? > Thanks
It would help us help you a lot of you copy/paste your code from both mydef.py and test.py so we can see exactly what you're doing. Don't re-type what you entered, because people (Especially new programmers) are prone to either making typos or leaving out certain things because they don't think they're important. Copy/Paste the code from the two files and then copy/paste the error you're getting. -- https://mail.python.org/mailman/listinfo/python-list