Results 1 to 4 of 4

Thread: Timing in Visual Basic 5.0

  1. #1

    Thread Starter
    New Member
    Join Date
    Jan 2000
    Posts
    4

    Post

    I am wondering how to make a form just sit there for 10 seconds and then run some code.

    I am designing a program and I need to get the first form in the series to pause and just sit there and be displayed for 10 seconds. After that, I would like it to hide that form and change to another.

    I know how to hide and show forms, but as for the 10 second delay, I need some help. Any help I receive in this matter is greatly appreciated

    ------------------
    Adam Hughes (SimGuy)
    [email protected]
    ICQ #: 19335996
    http://www.simcityhq.com/simport

  2. #2
    Addicted Member
    Join Date
    Jan 1999
    Location
    Sydney,NSW,Australia
    Posts
    178

    Post

    Ok don't have an exact answer....but...have used a call to the sleep API, to do something like this for a splash screen, or...could try a timer control with some sort of setfocus or timer1_click or something.

  3. #3
    Guru Clunietp's Avatar
    Join Date
    Oct 1999
    Location
    USA
    Posts
    1,844

    Post

    Add a timer to your form, interval of 10000, enabled = true

    On the Timer1_Timer event, add your code.

    It will execute after 10 seconds after the form loads

  4. #4

    Thread Starter
    New Member
    Join Date
    Jan 2000
    Posts
    4

    Post

    Thank you Clunietp and jritchie for the help. Both of your ideas worked great.

    Thanks again!

    ------------------
    Adam Hughes (SimGuy)
    [email protected]
    ICQ #: 19335996
    http://www.simcityhq.com/simport

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