Click here to Skip to main content
15,886,689 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
Hi ,
I want to use the zbar for barcode reading in IOS primarily. This may be cross platformed to windows too. I downloaded the libzbar.dll and tried to Pinvoke the methods which I listed via dumpbin /export.

I am getting a Pinvoke stack imbalance exception (?).
The questions are

1) How to avoid the stack imbalance? ie how to find the parameters for methods in the dll?

2) Is it ok to use *.dll file when I build for IOS or Can I do that at all?

Other than that any info on using a libzbar.a for cross platform development is appreciated.

Thanks
Posted
Updated 27-Mar-16 17:05pm
Comments
Richard MacCutchan 14-Nov-12 3:30am    
Go back to where you got the library and check the documentation.

1 solution

C#
In your PInvoke DllImport attribute, please change the CallingConvention to Cdecl or StdCall, this will solve your problem.

Hope it helps.
 
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