Free Memory

What is the best way to free memory in visual basic code after running an application..??


Comments

  • To unload forms with 'Unload' statement. But I think there is a better way to free memory in VB. simply now I can't remember another one.





  • : What is the best way to free memory in visual basic code after running an application..??


    Refer to the Set Statement in VB Help.

    Set Form1 = Nothing

    Set Form2 = Nothing

    etc.

    Assigning Nothing to objectvar releases all the system and memory resources associated with the previously referenced object when no other variable refers to it.





Sign In or Register to comment.

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Categories