Your problem is either one of two issues.

1) in the way that the server handles python scripts. The reason why
your python stops functioning is because the __init__ file is loaded
during server start-up. If you edit the __init__ file to add a new
python script to the server, you must restart the server. If you edit
a script and it has an error, it will tell you the error in the server
console window when you try to run the script.

2) When you added your files, you made a mistake in the __init__ file
or in the files you added. Be very careful of spacing, it has caused
scripts that I thought would work fine, not function at all.


Possible Solution:

Without your server running, make a copy of one of the files already
in the Samples folder. I suggest testobject.py as it will produce an
easy to see result. Rename this file to testMe.py.
Add the import command to your __init__.py file. These files are case-
sensitive. Start your server. If you made a mistake you will see an
error message in the server console window. Attempt to use your
script.

Example of what to class to point the object to if you used the
testobject.py file.

   testMe.Test

Click on the object and see if it works.

Hope this helps,
James



On Oct 25, 12:31 pm, Edwige Lelievre - ENER lab
<[email protected]> wrote:
> Hi everyone,
>
> I'm trying Modrex right now (server 0.5 and viewer 0.42) and I have a
> really strange scripting issue : when I add any python script in my
> local server, python doesn't work anymore (for any script, even python
> restart doesn't work). I add my scripts in rexserver\ScriptEngines
> \PythonScript\Samples folder, and then add it to the __init__.py
>
> I added scripts the same way with the 0.4 server, and it worked just
> fine.
>
> But when I don't add no script to the server, python works, I can even
> modify the scripts, it's ok.
>
> Thanks in advance.
>
> Edwige Lelièvre of ENER research groupwww.armaghia.fr
--~--~---------~--~----~------------~-------~--~----~
http://groups.google.com/group/realxtend
http://www.realxtend.org
-~----------~----~----~----~------~----~------~--~---

Reply via email to