Home     |     .Net Programming    |     cSharp Home    |     Sql Server Home    |     Javascript / Client Side Development     |     Ajax Programming

Ruby on Rails Development     |     Perl Programming     |     C Programming Language     |     C++ Programming     |     IT Jobs

Python Programming Language     |     Laptop Suggestions?    |     TCL Scripting     |     Fortran Programming     |     Scheme Programming Language


 
 
Cervo Technologies
The Right Source to Outsource

MS Dynamics CRM 3.0

C# Programming

Calling a VB Activex DLL method from C# (NET 1.1 - 2003)


When I build a project, I get this error:
Argument '1': cannot convert from 'double[]' to 'ref System.Array'

It is about a VB Activex DLL method that I am trying to call (using
System.Runtime.InteropServices).
Many arguments are arrays of double type, and for each one of them I get
that same error message.
I suppose I missed some pieces here.
Very grateful for some help.

>When I build a project, I get this error:
>Argument '1': cannot convert from 'double[]' to 'ref System.Array'

Call it like this

Array tmp = yourDoubleArray;
yourAxObj.SomeMethod(ref tmp);

You may want to use Tlbimp.exe to generate new interop assemblies with
strongly typed array parameters instead.

Mattias

--
Mattias Sjgren [C# MVP]  mattias @ mvps.org
http://www.msjogren.net/dotnet/ | http://www.dotnetinterop.com
Please reply only to the newsgroup.

Add to del.icio.us | Digg this | Stumble it | Powered by Megasolutions Inc