Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

cannot convert parameter 1 from 'cli::array<Type> ^*' to 'System::Obje

Status
Not open for further replies.

duongthaiha

Programmer
Mar 21, 2007
11
GB
Hi
I have the following code. The method will is declared as
int __stdcall GrCapRawImageToHandle(unsigned char* rawImage, unsigned int width, unsigned int height, HDC hdc, HBITMAP &handle);

I think that is old syntax style and i have use that in my code in VisualStudio 2005

System:rawing::Image ^handle;
Graphics ^g= btn_startCap->CreateGraphics();
IntPtr hdc = g->GetHdc();
array <unsigned char> ^img ;
//System::Object ^img = gcnew Object();
int width=355;
int height=390;
axGrFingerXCtrl1->CapRawImageToHandle(img,width,height,hdc.ToInt32(),handle);
Image ^curImage = handle;
picBox_main->Image=curImage;

And it come back to me as

error C2664: cannot convert parameter 1 from 'cli::array<Type> ^*' to 'System::Object ^%'


Can you please tell how should i declare the variable to pass it to the method?


Thanks a lot for your help

I do apreciate that
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top