Re: Looking for a little education on VBA code

Tech-Archive recommends: Speed Up your PC by fixing your registry

From: Marc (mPAMpaisl_at_optusnet.com.au)
Date: 04/15/04


Date: Fri, 16 Apr 2004 08:44:12 +1000


<snip>
> On your point a), my uncertainty was based on the mechanics of duplicating
the data set. Was a duplicate table being created and then deleted, making
it temporary or was the duplicate made 'virtually' where it would never show
up in the db window.
>
> After reading your comment, I checked the db window and could not see any
new object named rs so I guess that rs is a virtual object occupying memory
space. I had assumed that the object would delete itself when the form
closed, but your comment that it needs to be closed and set to nothing makes
me wonder about my assumption. Does the rs object stay in memory until the
program closes? Or is it only until the form closes?
>
> If it is residing in memory, then how/where would I go about closing and
setting it to nothing? Would I add code to the form's Close event? Or add
another line at the end of the control's afterupdate event code? How would
that line read? Possibly ' Set rs = Null ' or ' Delete rs '?
>
> Thanks for joining this discussion and helping me out.
>
> Rick...
>
Hi
It is only created in memory, and you need first the close statement and
then the null statement. I'm not sure of the exact technical description,
but the rs is an object, not a variable. In Access and other products,
objects can have a different scope to local variables. Therefore if you are
finished with an object you need to explicitly say so.

Marc



Relevant Pages

  • Re: Reading via mmap stinks (Re: weird bugs with mmap-ing via NFS)
    ... :before the memory had to be reclaimed forcibly by the VM system. ... Now that data set could fit into memory if portions of your UI were ... set should the kernel fit into memory, but which portions of that data ... Scenario #1: If the kernel fits the whole 900MB data set into memory, ...
    (freebsd-stable)
  • Re: spreadsheet is crashing excel in Mac, but works fine in PC
    ... In addition to what Bob said, there is a memory issue there. ... With only 2GB of memory, when Excel wants to open a large data set, it is ... Mac OS X 10.5.8 ...
    (microsoft.public.mac.office.excel)
  • [RFC 1/2] kmemdup: introduce
    ... One of idiomatic ways to duplicate a region of memory is ... memcpy(dst, src, len); ... With kmemdup, the snippet above will be rewritten as: ...
    (Linux-Kernel)
  • Re: spreadsheet is crashing excel in Mac, but works fine in PC
    ... In addition to what Bob said, there is a memory issue there. ... With only 2GB of memory, when Excel wants to open a large data set, it is ... Excel 2008 for Mac, version 12.1.9 ...
    (microsoft.public.mac.office.excel)
  • Re: Large RAM sizes in embedded systems
    ... with relatively large amounts of directly-addressable RAM. ... My usual cases for that is video memory so organisation is different. ... Ah the BMFdata set scenario that relates to many embedded apps. ... Consider how older systems did bank/page/MMU selection. ...
    (comp.arch.embedded)