Bob Schneider
asked on
Variable uses and automation type not supported in visual basic
I am trying to write records to a vb list box and one field is of the "time" variable type. I get the error message indicated in the post title even when I try to write it as CStr(value). Any ideas?
Can you post your workbook?
ASKER
Here is my code:
Set rs = New ADODB.Recordset
sql = "SELECT Bib, Chip, Time, Reader, Antenna FROM RawRFID WHERE EventID = " & lEventID
rs.Open sql, conn, 1, 2
If rs.RecordCount > 0 Then
RawReads = rs.GetRows()
Else
ReDim RawReads(4, 0)
End If
rs.Close
Set rs = Nothing
For i = 0 To UBound(RawReads, 2)
lstRawData.AddItem i + 1 & vbTab & RawReads(0, i) & vbTab & RawReads(1, i) & vbTab & RawReads(2, i) & vbTab & RawReads(3, i) & vbTab & RawReads(4, i)
Next i
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
The problem is that, as I write it to the array, I can't transfer it to the list box even if I convert it to a string. I think I will just change the data type. I don't think it needs to be Time necessarily. I will leave this open in the event someone has a better solution.
I think I will just change the data type.That's what I was suggesting in my previous post.
I'm glad I was able to help.
In my profile you'll find links to some articles I've written that may interest you.
Marty - MVP 2009 to 2014
In my profile you'll find links to some articles I've written that may interest you.
Marty - MVP 2009 to 2014
ASKER
I will look at that. Thanks so much!!!