"vba convert endianess" Code Answer's
You're definitely familiar with the best coding language VBA that developers use to develop their projects and they get all their queries like "vba convert endianess" answered properly. Developers are finding an appropriate answer about vba convert endianess related to the VBA coding language. By visiting this online portal developers get answers concerning VBA codes question like vba convert endianess. Enter your desired code related query in the search bar and get every piece of information about VBA code related question on vba convert endianess.
vba convert endianess

'Extremely fast VBA function to convert a LONG value from Little-Endian
'to Big-Endian byte order representation, and vice versa:
Function ConvertEndianness&(ByVal n&)
ConvertEndianness = (((n And -16777216) \ 16777216) And 255&) Or _
((n And 16711680) \ 256&) Or ((n And 65280) * 256&) Or ((n And 127&) * 16777216)
If (n And 128&) Then ConvertEndianness = ConvertEndianness Or &H80000000
End Function
'------------------------------------------------------------------------------------------------
MsgBox ConvertEndianness(127) '<--displays: 2130706432
MsgBox ConvertEndianness(2130706432) '<--displays: 127
'NB: This function converts byte order: &h12345678 --> &h78563412
' &h78563412 --> &h12345678
'Reference:
https://en.wikipedia.org/wiki/Endianness
Source: academy.excelhero.com
All those coders who are working on the VBA based application and are stuck on vba convert endianess can get a collection of related answers to their query. Programmers need to enter their query on vba convert endianess related to VBA code and they'll get their ambiguities clear immediately. On our webpage, there are tutorials about vba convert endianess for the programmers working on VBA code while coding their module. Coders are also allowed to rectify already present answers of vba convert endianess while working on the VBA language code. Developers can add up suggestions if they deem fit any other answer relating to "vba convert endianess". Visit this developer's friendly online web community, CodeProZone, and get your queries like vba convert endianess resolved professionally and stay updated to the latest VBA updates.