hi everyone,
i want to store a decimal value into a QByteArray.

Qt Code:
  1. int num = 43981;//abcd
  2. QByteArray byte((const char*)&num,sizeof(num);//byte[0] =cd,byte[1]=ab
To copy to clipboard, switch view to plain text mode 


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.