0
Answer

C# Embedding IronPython?

Ask a question
Mastermosley

Mastermosley

13y
1.9k
1
I have succesfully been able to pass variables from C# to my python scripts and run them succesfully but the problem I have is that the entire script needs to be compiled before the script sends data. What I am trying to accomplish is having the program actually flow into the script. For example say I have a telnet server and sockets and IO processing is done in C#. Now I create a login script in python and pass the IO class from C# to python. In my python script I send a welcome message through the IO class but I want to wait for a response and then decide what to do next. This is not possible since the entire script has to be compiled so the script would be endlessly waiting for a response that it will never recieve.

Is there any other way to do this? Any suggestions?

Thanks.