Mega Code Archive

 
Categories / VB.Net / Development
 

BitConverter GetBytes returns the specified Boolean value as an array of bytes

Imports System Imports Microsoft.VisualBasic Module GetBytesBoolDemo     Sub GetBytesBool( argument As Boolean )         Dim byteArray As Byte( ) = BitConverter.GetBytes( argument )         Console.WriteLine( BitConverter.ToString( byteArray ) )     End Sub      Sub Main( )         GetBytesBool( True )     End Sub  End Module