Results 1 to 2 of 2
  1. #1
    Join Date
    Jan 2005
    Posts
    2

    Unanswered: DAO and Excel memory leak?

    Hi,

    I use a DAO recordset to change some values in an excel worksheet. The problem is every time the update method from the recordset is fired the memory usage increases and stays allocated. Is this a known issue? Here is some pseudo-code to show you where the problem is:

    Code:
    Dim db as DAO.Database
    Dim rs as DAO.Recordset
    ...
    Set db = ...
    Set rs = db.OpenRecordset("Sheet1$", dbOpenDynaset)
    ...
    While ...
       rs.FindFirst "searchstring"
       If Not rs.NoMatch Then
          rs.Edit
          rs!Field = "Data"
          rs.Update 'Memory usage increases here!
       End If
    Wend
    ...
    rs.Close
    Set rs = Nothing
    Set db = Nothing
    ...
    I hope someone can help me out here,

    Thx in advance,

    RaKKeR

  2. #2
    Join Date
    Dec 2004
    Location
    York, PA
    Posts
    95
    rs.Close
    Set rs = Nothing
    db.close
    Set db = Nothing
    Sorry to be terse
    some say it's a curse
    I know it's worse
    I'm just diverse

Posting Permissions

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