test bit value in a word or double word

Hi,

is there a function in xojo to test a bit value in a word or double word?

Best Regards

Fabio

Apply a mask using “and”. For example, let’s say I wanted to test the third bit in an Int32:

dim v as Int32 = someValue
dim mask as Int32 = &b00100000000000000000000000000000

if ( v and mask ) <> 0 then
  // The bit is set
end if

Thank you very much!