Results 1 to 5 of 5

Thread: Close program

  1. #1

    Thread Starter
    The Devil crptcblade's Avatar
    Join Date
    Aug 2000
    Location
    Quetzalshacatenango
    Posts
    9,091
    When I use the:

    Unload FormName

    method, the form disappears, but if I try to delete the program the computer says that the program is in use.

    Am I not using the correct command to close the program?

  2. #2
    Addicted Member hypnos's Avatar
    Join Date
    Aug 2000
    Location
    UK
    Posts
    183

    Wink

    Use the End command to close a program.

  3. #3
    _______ HeSaidJoe's Avatar
    Join Date
    Jun 1999
    Location
    Canada
    Posts
    3,946

    <?>

    Code:
    'use this in your unload event
    
    Dim Form As Form
       For Each Form In Forms
          Unload Form
          Set Form = Nothing
       Next Form
    "A myth is not the succession of individual images,
    but an integerated meaningful entity,
    reflecting a distinct aspect of the real world."

    ___ Adolf Jensen

  4. #4
    Guest
    The difference between the 2 is Unload will trigger the unload events (QueryUnload, Unload and Terminate), and End will not.

  5. #5
    _______ HeSaidJoe's Avatar
    Join Date
    Jun 1999
    Location
    Canada
    Posts
    3,946

    <?>

    and it's also a good habit to set your
    objects = nothing!
    "A myth is not the succession of individual images,
    but an integerated meaningful entity,
    reflecting a distinct aspect of the real world."

    ___ Adolf Jensen

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