forum

Home / DeveloperSection / Forums / Converting data of NSData into bytes array in iOS

Converting data of NSData into bytes array in iOS

Anonymous User 1831 20-Nov-2015

I have getting problem with conversion of NSData into bytes array.
this is the code that I am using:

NSData *myData = [NSData dataWithContentsOfFile:pathOfFile];
int dataLength = [myData length];
Byte byteData[dataLength];
byteData = [myData bytes];

My last line generating error 'incompatible types in assignment'.
Can anyone tell me the correct way to do it.


Updated on 20-Nov-2015
I am a content writter !

Can you answer this question?


Answer

1 Answers

Liked By