I have the following code:


Private Type test
a As String * 20
b As String * 20
End Type

Sub Workbook_Open()
Open "testfile" For Random As #1
a = "First Name"
b = "Last Name"
Put #1, 1, test
Close #1
a = " "
b = ""
Open "testfile" For Random As #1
Get #1, 1, test
Worksheets("Sheet1").Cells(2, 1) = a
Worksheets("Sheet1").Cells(2, 2) = b
End Sub

yet when I execute, the cells targeted come up blank. It has something to do with the sub not recognized the variable declared in Type--End Type. I'm missing something really stupid, I know, I just can't see it. Can anyone help?

Thanks

k483