Click to See Complete Forum and Search --> : Is it possible to create class or type with bit field


F.Mayis
May 18th, 2001, 07:37 AM
Hi,
All is in the subject.

In C/C++ i have a structure:

typedef struct titi{
unsigned char field1:1;
unsigned char field2:1;
unsigned char field3:2;
unsigned char field4:1;
}titi;

now i have a program in VB that must fill this structure and put it in a binary file.
But i don't know if bit field is possible in VB

thanks!

Cimperiali
May 18th, 2001, 09:46 AM
maybe binary type can help you
ie:
dim theBField() as binary
Redim theBField(lendesired)
have a look at binary files in msdn.

Special thanks to Lothar "the Great" Haensler, Tom Archer, Chris Eastwood Bruno Paris and all the other wonderful people who made and make Codeguru a great place. Come back soon, you Gurus.