Click here to Skip to main content
15,890,282 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hello,

I have One Function Return In VC++....Which Is Accepting 2d Array As Parameter ..
C++
declspec(dllexport) void add(int* a)
	{
		//A is 2D Array 
               //    Fill Some Data in Array


	}


Call From C#

C#
main()
{
add(out aa[0])//How To Pass 2d Array Here
}

I want To Pass This 2d Array To Function Written In Dll Of VC++(Unmanaged Code)....

Any help..
Thanks In Advance.......
Posted

1 solution

You need to use the P/Invoke mechanism as described here[^].
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900