How do I convert double datatype from small endian to big endian and vice versa in c#. Your help will be highly appreciated.
Regards, Sidharth Shah
public static byte[] GetBigEndianBytesFromDouble(double value) { byte[] b; b=BitConverter.GetBytes(value); if (BitConverter.IsLittleEndian) Array.Reverse(b); return b; }