Re: Put Object Containing Object
- From: "Bob Butler" <noway@xxxxxxxxxxx>
- Date: Thu, 16 Aug 2007 18:15:33 -0700
"Lorin" <Lorin@xxxxxxxxxxxxxxxxxxxxxxxxx> wrote in message news:62AD9EAE-82D6-4EA3-9487-3221E6C7E754@xxxxxxxxxxxxxxxx
Since Put will not allow putting Objects that contain objects, is there a way
to wrap this object with an object in something that Put will work with?
ignoring the fact that types are not objects in VB, this code works fine
Private Type RECT
Left As Long
Top As Long
Right As Long
Bottom As Long
End Type
Private Type uHeaderInfo
Caption As String
Rectangle As RECT
TextAlign As Long
End Type
Private uHdr() As uHeaderInfo
Sub Main()
ReDim uHdr(5)
uHdr(1).Rectangle.Top = 42
Open "c:\x" For Binary As #1
Put #1, , uHdr(1)
Close #1
Open "C:\x" For Binary As #1
Get #1, , uHdr(2)
Close #1
MsgBox uHdr(2).Rectangle.Top
End Sub
Maybe if you explain what actual error you are getting or what the problem is somebody can help.
.
- Follow-Ups:
- Re: Put Object Containing Object
- From: Stefan Berglund
- Re: Put Object Containing Object
- Prev by Date: Re: VB6 and Crystal Reports 11 works slowly on Vista.
- Next by Date: Re: for the VB6 experienced
- Previous by thread: Re: Put Object Containing Object
- Next by thread: Re: Put Object Containing Object
- Index(es):
Relevant Pages
|