convert types from IronPython to C#
-
Hi, I have a C# code that include a python script one of my python function return a Tuple, let say:
def Example():
a = 3
b = 4
return a, bnow I want to call the Example function from my C# code, but this function return a tuple. How do I handle this? Thanks
-
Hi, I have a C# code that include a python script one of my python function return a Tuple, let say:
def Example():
a = 3
b = 4
return a, bnow I want to call the Example function from my C# code, but this function return a tuple. How do I handle this? Thanks
-
Hi, I have a C# code that include a python script one of my python function return a Tuple, let say:
def Example():
a = 3
b = 4
return a, bnow I want to call the Example function from my C# code, but this function return a tuple. How do I handle this? Thanks
i've find that, from ironPython documentation: Appendix - Type conversion rules http://ironpython.net/documentation/dotnet/dotnet.html#appendix-type-conversion-rules[^] tuple with T-typed elements -> System.Collections.Generic.IEnumerable or System.Collections.Generic.IList i guess that when you reference the ironPython code into your C# code, you should use a IEnumerable the full integration documentation: http://ironpython.net/documentation/dotnet/[^] sorry by the english, i'm brazilian and aren't fluent.. :((
-
i've find that, from ironPython documentation: Appendix - Type conversion rules http://ironpython.net/documentation/dotnet/dotnet.html#appendix-type-conversion-rules[^] tuple with T-typed elements -> System.Collections.Generic.IEnumerable or System.Collections.Generic.IList i guess that when you reference the ironPython code into your C# code, you should use a IEnumerable the full integration documentation: http://ironpython.net/documentation/dotnet/[^] sorry by the english, i'm brazilian and aren't fluent.. :((