Answers for "office vba change integer to 32bits"

VBA
5

excel vba low word from Long Integer

'If n is a 4-byte Long Integer, the Low (Left) Word is:
If n And &H8000& Then
  	LoWord = n Or &HFFFF0000
Else
    LoWord = n And &HFFFF&
End If

'If n is a 4-byte Long Integer, the High (Right) Word is:
HiWord = (n And &HFFFF0000)  &H10000
Posted by: Guest on May-23-2020
4

excel vba convert 2 Short integers to a Long integer

Public Function MakeLong&(ByVal LoWord%, ByVal HiWord%)
  MakeLong = (HiWord * &H10000) Or (LoWord And &HFFFF&)
End Function
Posted by: Guest on May-23-2020

Code answers related to "VBA"

Browse Popular Code Answers by Language