Frage

I really need help here. I'm pretty new to iOS/Objective-C so sorry if the problem resolution is simple.

I have followed all of the steps on the zBar tutorial in order to get the barcode reader working but I have had no success. I noticed that one of the steps said:'Declare support for the delegate protocol in ReaderSampleViewController.h'; when I pasted the code below, I started to get an error. Have I done something wrong here?

@interface ReaderSampleViewController : UIViewController
// ADD: delegate protocol
< ZBarReaderDelegate >

{ ...

War es hilfreich?

Lösung

Make sure it looks like this. Also the simulator has to be set for 3.5inch as zbar's sdk doesn't support 4inch as of now. Thats actually what I am trying to fix now. If I find a fix I will post that back here as well.

#import "ZBarSDK.h"
@interface ReaderSampleViewController : UIViewController <ZBarReaderDelegate>

EDIT: Found the solution for 4 inch aka iPhone 5's here:http://www.federicocappelli.net/2012/10/05/zbar-library-for-iphone-5-armv7s/

Lizenziert unter: CC-BY-SA mit Zuschreibung
Nicht verbunden mit StackOverflow
scroll top