Hello Andrew,
VB doesn't support the same syntax for structures that C does. VB calls
structures User Defined Types. For example, if you have the following
struct defined in C:
typedef struct fred
{
int x;
int y;
int cx;
int cy;
Quote:
} FRED;
You would have to define that as a type in VB like so:
Type Fred
x as Long
y as Long
cx as Long
cy as Long
End Type
You could then create variables based on Fred using the VB syntax:
Dim myFred as Fred
And fill its members similar to the way you do in C:
myFred.x = 222
myFred.y = 333
myFred.cx = 100
myFred.cy = 200
I hope this helps,
Larry Tubbs, MCPS, MCSD
Silverleaf Vacation Club
http://www.*-*-*.com/ ~enigma/
Quote:
> Can someone please give me a hand with utilizing
> C structs in
VBA (specifically VBA for Office 95)
> I would like to read/write struct's from a file from
> within MS Access 95. I'm new to programming
> in VBA.
> Thanks very much!
> Andrew Delic