0
Answer

SafeArray in C#

Photo of Pat

Pat

18y
4k
1
I have this method from an ocx that is expecting safearray object as arguments

ocx.GetData(ref object ySafeArray, ref object xSafeArray, ref int pts, ref double xbeg, ref double xend);

How do I create a SafeArray object in C# for the first two arguments? I did something like this...but that does not seem to work.

object yArray = new object();
object xArray = new object();

Thanks