Private Type blah
name As String
plan As String
goal As String
number As Integer
End Type
Private Sub Form_Load()
Dim b As blah
b.name = "Just some guy"
b.plan = "eat yummies and get fat like sumo wrestler so all the asian girls will want me ;)"
b.goal = "find a decent job that actually pays me for my skills and abilities :-\"
b.number = 3
f = FreeFile
Open "c:\blah.txt" For Binary As f
Put f, , b
Close f
Dim ha As blah
Open "c:\blah.txt" For Binary As f
Get f, , ha
Close f
MsgBox "Object data read in from saved file:" & vbCrLf & vbCrLf & _
"blah.name = " & ha.name & vbCrLf & _
"blah.plan = " & ha.plan & vbCrLf & _
"blah.goal = " & ha.goal & vbCrLf & _
"blah.number=" & ha.number
End Sub