I need to convert a 4-byte bool for a transmission to a server.
This is my value:
bool DROIT_PRIO = false;
I already try like this:
var TYPE_DROIT_ARRAY = BitConverter.GetBytes(DROIT_PRIO);
Obtained result (in hexa): 00
Expected result :
False : 00-00-00-00
True : 01-00-00-00
How I can pass my value in bytes[]
to obtain this result?