On Wed, 05 Oct 2005 13:46:30 +0530, Iyer, Prasad C wrote:
>
> Actually I am bit confused between the modules and .py file
> How do I differentiate between the 2.
>
> For example
> I have a file import1.py, import2.py file
>
> Which has few functions and classes
> And if I have a class with same
: Re: Confused with module and .py files
#
#Iyer, Prasad C wrote:
#> Actually I am bit confused between the modules and .py file
#> How do I differentiate between the 2.
#>
#> For example
#> I have a file import1.py, import2.py file
#> Which has few functions and classes
#> And i
Iyer, Prasad C wrote:
> Actually I am bit confused between the modules and .py file
> How do I differentiate between the 2.
>
> For example
> I have a file import1.py, import2.py file
> Which has few functions and classes
> And if I have a class with same name "BaseClass" in both the file
>
> How
"Iyer, Prasad C" wrote:
> How would I use it if I declare it as given below in my 3rd class
>
> from import1.py import *
> from import2.py import *
thats a syntax error; I assume you meant
from import1 import *
from import2 import *
which simply doesn't work if you need to access things
Iyer, Prasad C wrote:
> Actually I am bit confused between the modules and .py file
> How do I differentiate between the 2.
>
> For example
> I have a file import1.py, import2.py file
> Which has few functions and classes
> And if I have a class with same name "BaseClass" in both the file
>
> How
Iyer, Prasad C wrote:
>Actually I am bit confused between the modules and .py file
>How do I differentiate between the 2.
>
>
>
A module 'name' is the same as the name of your file without the '.py'
extension.
>For example
>I have a file import1.py, import2.py file
>Which has few functions and
Actually I am bit confused between the modules and .py file
How do I differentiate between the 2.
For example
I have a file import1.py, import2.py file
Which has few functions and classes
And if I have a class with same name "BaseClass" in both the file
How would I use it if I declare it as give