Re: API calls and &H1, &H2, &H4, &H8, ..., &H10, ..., H40000, ....
From: Ken Halter (Ken_Halter_at_Use_Sparingly_Hotmail.com)
Date: 09/17/04
- Next message: Mike Burton: "Shell command failing inside a late-bound object created inside a late-bound object"
- Previous message: Bob O`Bob: "altering the modified date/time of a Word document"
- In reply to: Joe: "API calls and &H1, &H2, &H4, &H8, ..., &H10, ..., H40000, ...."
- Next in thread: Larry Serflaten: "Re: API calls and &H1, &H2, &H4, &H8, ..., &H10, ..., H40000, ...."
- Reply: Larry Serflaten: "Re: API calls and &H1, &H2, &H4, &H8, ..., &H10, ..., H40000, ...."
- Reply: MikeD: "Re: API calls and &H1, &H2, &H4, &H8, ..., &H10, ..., H40000, ...."
- Messages sorted by: [ date ] [ thread ]
Date: Fri, 17 Sep 2004 11:09:17 -0700
Joe wrote:
> Okay, I came into VB without *ever* learning about the hexadecimal notation.
> What do the following mean and what decimal numbers do they translate to?
>
> &H10 (is this equal to 16?)
Yup...
> &H400 (is this equal to 256?)
&h400's = 1024.
> If they are, why do I use these in API calls in lieu of 16 and 256?
There's really no reason. Hex is easier to read and mentally process if
you're going to end up breaking the value up into numerical "words".
Each letter represents a nibble of data (4 bits). 2 letters per byte (8
bits) and so on.
fwiw, If you fire up Windows Calculator and select the 'View/Scientific'
menu, you'll have a way to calculate hex/binary/etc.
-- Ken Halter - MS-MVP-VB - http://www.vbsight.com Please keep all discussions in the groups..
- Next message: Mike Burton: "Shell command failing inside a late-bound object created inside a late-bound object"
- Previous message: Bob O`Bob: "altering the modified date/time of a Word document"
- In reply to: Joe: "API calls and &H1, &H2, &H4, &H8, ..., &H10, ..., H40000, ...."
- Next in thread: Larry Serflaten: "Re: API calls and &H1, &H2, &H4, &H8, ..., &H10, ..., H40000, ...."
- Reply: Larry Serflaten: "Re: API calls and &H1, &H2, &H4, &H8, ..., &H10, ..., H40000, ...."
- Reply: MikeD: "Re: API calls and &H1, &H2, &H4, &H8, ..., &H10, ..., H40000, ...."
- Messages sorted by: [ date ] [ thread ]
Relevant Pages
|