sattu
20th January 2011, 13:33
hi everyone,
i want to store a decimal value into a QByteArray.
int num = 43981;//abcd
QByteArray byte((const char*)&num,sizeof(num);//byte[0] =cd,byte[1]=ab
this stores the number.But it in reverse way.ie byte contain "cd ab".
But i want to store in "ab cd" way.
plz help me.
i want to store a decimal value into a QByteArray.
int num = 43981;//abcd
QByteArray byte((const char*)&num,sizeof(num);//byte[0] =cd,byte[1]=ab
this stores the number.But it in reverse way.ie byte contain "cd ab".
But i want to store in "ab cd" way.
plz help me.