Page 1 of 1
Importing
Posted: Wed Aug 17, 2011 4:01 pm
by cfull1
Is there a way to import files into a plugin not from that folder?
Like if I installed something and its in python27\Libs.
Is there anyway to import that?
Re: Importing
Posted: Tue Aug 23, 2011 12:04 am
by eatmeimadanish
If you are talking about modules inside of Python (IE import MySQLdb) then yes you can. You should probably run the same version of Python thats in EG which is currently 2.6.5. For instance I just imported MySQLdb into EG by droping all of the files into C:\Program Files (x86)\EventGhost\lib26\site-packages that pertained to that module. Now I can access a MySQL database directly from EG.
Re: Importing
Posted: Tue Aug 23, 2011 5:50 am
by cfull1
Nice! This is what I was looking for thanks. I've got 2.7 installed, not that much different right?