Qbasicnews.com

Full Version: Would anyone care to explain this...
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
I'm using Ems copying routines where I want to to copy 64K. When I use &HFFFF it doesn't work, but when I use 65535, it works. Is that maybe due to the function which doesn't accept hexidecimal notation?
QB interprets &HFFFF as an integer, a signed 16 bit integer, because it's 4 hex digits. But you can put an & on the end of the number, like this: &HFFFF&, to override that.

Hex numbers longer than 4 digits are taken as LONGs, but putting on a leading zero doesn't work because QB's IDE strips out leading zeros. So if the & doesn't work, you may have to do something tricky, like this: (&H10FFFF - &H100000).
Cool, thanks 8)