Recordset

  • Thread starter Thread starter Brad
  • Start date Start date
B

Brad

Thanks for taking the time to read my question.

I would like to create a recordset that is just a
recordset. I don't want to base it off of a table or a
query. I just want to save a few values for a very short
period of time, and then be able to look them up when
needed.


So far all I know is

Dim dbs as Database, rst as Recordset, fld as field

I don't know if I need to Dim a TableDef or not.
All I need is one field in the recordset.

Thanks again,

Brad
 
By definition a Recordset object represents the records in
a base table or the records that result from running a
query, so you can't have a recordset without a table or
query.

I think what you're describing is an array variable.

Dim str as String
Dim myArray(4) as Variant
myArray(0) = "John"
myArray(1) = "Doe
myArray(3) = 123
myArray(4) = "Main Street"
str = myArray(0) & " " & myArray(1) & " lives at " _
myArray(3) & " " & myArray(4)
MsgBox str

Arrays can be multi-dimentional and sized according to
need by using the 'ReDim Preserve' statement. They're in
your help file. Good luck.
 
Back
Top