Results 1 to 2 of 2

Thread: recordset that not connect to DB

  1. #1

    Thread Starter
    Lively Member
    Join Date
    Oct 2000
    Location
    jerusalem
    Posts
    72

    Angry

    How can I create a recordset that is not!! connected to the db but I by myself want to add columns and rows to this recordset.

    For example ADODB.Recordset is connected to db according
    to source that I previuosly defined. The question is if there is any rs that does not connect to the db.

    Thank you,
    Roy

  2. #2
    Fanatic Member
    Join Date
    Oct 2000
    Location
    London
    Posts
    1,008

    Disconnected and stand-alone recordsets

    Yes, you can do this.

    ADO has support for stand-alone and file-based recordsets.

    Code:
    Dim rs As New ADODB.Recordset
    rs.Fields.Append "FirstField", adChar, 40 etc...
    rs.Fields.Append.....
    rs.Open
    rs.AddNew etc.
    Note that you can define data types and data options (adFldIsNullable etc.)

    You can use this technique to read file based data into your recordset (or Arrays, or UDTs or HTML or whatever!)

    Hope that helps...

    Paul.
    Not nearly so tired now...

    Haven't been around much so be gentle...

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width