I am trying to understand how to pass a multi-dimensional array of float from IronPython code to a C# library.
Here is the C# code I am trying to call (This is a function is a library class I am importing into my IronPython code):
public void ShowMessage(double[,] values)
This is the my IronPython code:
import clr
clr.AddReferenceToFile(r"DisplayLib.dll")
from DisplayLib import Display
display = Display()
a = [[1.2, 1.3, 1.4, 1.5],
[2.2, 2.3, 2.4, 2.5]]
display.ShowMessage(a)
I am getting the following exception: "expected Array[float], got list" then I tried to convert the array to a tuple but it only worked for a 1D array.
Any suggestions on how do this?