Results 1 to 6 of 6

Thread: Please, make my form dissappear!!!

  1. #1

    Thread Starter
    Lively Member
    Join Date
    May 1999
    Location
    Vancouver, BC, Canada
    Posts
    84
    At the begining of long series of calculations, I want to immediately minimize or set my form's visible prop to false. In other words, make the form dissappear.

    However, neither action actually occurs until the calculation are completed.

    I tried refresh but it has no effect.

    Any ides???

    Jon

  2. #2
    Fanatic Member
    Join Date
    Oct 1999
    Location
    MA, USA
    Posts
    523
    Have you tried to add DoEvents to your code?

  3. #3
    Frenzied Member Jop's Avatar
    Join Date
    Mar 2000
    Location
    Amsterdam, the Netherlands
    Posts
    1,986
    At the begining of long series of calculations, I want to immediately minimize or set my form's visible prop to false...

    You set it at the beginning to false or what? Please post some code (at least the part where you set it to false and the calculations, we may be able to help ya!
    Jop - validweb.nl

    Alcohol doesn't solve any problems, but then again, neither does milk.

  4. #4
    Member
    Join Date
    Mar 2000
    Location
    Mentor,Oh,US
    Posts
    33

    Cool

    I do beleive you can do one of these two. And make sure you place them just before the calculation code. You can minmize or hide a form and still have the code execute correctly. This is called, "working in the background."

    Code:
    Form1.Hide
    
    (or)
    
    Form1.Visible = False

    Try the Hide Method first and tell me how if it works.
    If at first you DO succeed, don't look too astonished!
    -deadBird
    =================

  5. #5

    Thread Starter
    Lively Member
    Join Date
    May 1999
    Location
    Vancouver, BC, Canada
    Posts
    84
    Thanks Guys,

    I got some help and found an answer. Its a game without a title bar. Has a Minimize button so people can play at work! Also has an Exit button. Program does a lot of calculating and may need to be minimized or exited during these calcs. Here's the code that works:

    "Lots of Do Whiles"
    "Lots of calculations"
    DoEvents
    If Forms.Count < 1 Then Exit Sub
    "More Calcs"
    "Lots of Loops"

    DoEvents handles the Minimize & Exit buttons. The Exit button Unloads the form but the code will try to continue to run which results in errors. The If...Then stops the code.

    Thanks for all the help,
    Jon

  6. #6
    Fanatic Member
    Join Date
    Jun 1999
    Location
    California, USA
    Posts
    662
    You might also try a DoEvents at the beginning of each of your loops

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