| Reply | « Previous Thread | Next Thread » |
|
Sorry for yet another post but the nokia forum search is not good.
It is a very simple question. I have created a module and I want to import it into my main one? Where should I put it? When I put it in the Python directory it does not find it I am sure i have written it right (exactlly like the name of the file with the module)Thank you |
|
Hello Zamoth_bg,
I'd place it on "e:\\python\\lib" for development and later in your final application on c:\\python\\lib To make shure that your script'll always find your modules put the following at the very beginning of your script: Code:
import sys, os, os.path
for path in ('c:\\python\\lib','e:\\python\\lib'): #path to your modules
if os.path.exists(path):
sys.path.append(path)
|
|
Thank you very much!
|
| Reply | « Previous Thread | Next Thread » |
| Thread Tools | Search this Thread |
|---|---|
| Rate This Thread | |
| Thread | Thread Starter | Forum | Replies | Last Post |
|---|---|---|---|---|
| Error import module | akus | Python | 0 | 2007-10-21 20:47 |
| problem on running my application | rsf | Python | 7 | 2007-10-21 16:56 |
| Carbide.j 1.5 and Netbeans 5.5 beta 2 | ovjo12 | Mobile Java Tools & SDKs | 5 | 2007-06-11 06:43 |
| how put FullCanvas.class into the project, and use without import from api?? | fredrischter | Mobile Java General | 1 | 2007-05-22 11:25 |
| GoogleIt | deepika.mangla | General Symbian C++ | 4 | 2007-01-08 02:07 |