Results 1 to 9 of 9
  1. #1
    Join Date
    Oct 2002
    Location
    Leicester - UK
    Posts
    820

    Unanswered: Is there any way to pause a form?

    i want a form to sit and do nothing until woken up by another form can it be done?
    Definition of a Beginner, Someone who doesn't know the rules.

    Definition of an Expert, Someone who knows when to ignore the rules.

  2. #2
    Join Date
    Sep 2002
    Location
    South Wales
    Posts
    580

    Lightbulb Try this?

    Forms!frmyourformname.Visible = False
    ...to hide it

    Calling form says...
    Forms!frmyourformname.Visible = True

  3. #3
    Join Date
    Oct 2002
    Location
    Leicester - UK
    Posts
    820
    wont help forms hidden not paused what i need basicly... well let give some background

    i've got a form that opens another form which asks the user if they wish to send an email informing the person the record is about that there data has change now this works perfectly well unless the close form command is given then it runs the form and closes the main form before the second fom can process the data on it if the user wants to send an email so i need the 1st form to open the second form wait for it to close and then close it's self every other method i've tried fails beacuse of the fact that i that variable try to change in the wrong order between the two forms because neither will wait for the other

    so i need to exerces some process control but i can't find the required methods
    Last edited by m.timoney; 03-04-03 at 12:35.
    Definition of a Beginner, Someone who doesn't know the rules.

    Definition of an Expert, Someone who knows when to ignore the rules.

  4. #4
    Join Date
    Aug 2002
    Location
    Charlotte NC
    Posts
    665
    Originally posted by m.timoney
    wont help forms hidden not paused what i need basicly... well let give some background

    i've got a form that opens another form which asks the user if they wish to send an email informing the person the record is about that there data has change now this works perfectly well unless the close form command is given then it runs the form and closes the main form before the second fom can process the data on it if the user wants to send an email so i need the 1st form to open the second form wait for it to close and then close it's self every other method i've tried fails beacuse of the fact that i that variable try to change in the wrong order between the two forms because neither will wait for the other

    so i need to exerces some process control but i can't find the required methods
    umm just to get this clear u need a way to pause the first form from closing untill the second form is closed?
    this is just off the top of my head so i havent had a chance to see if this is even posable but...can you try a do while loop on the first form. the loop checks a variable say Form_Closed.
    While the varaible form_closed = no then loop. when the variable = yes then docmd.close.
    have the second form set the variable just before it closes.

    Thats just a thought...ill look more into if thats even posable
    Jim

  5. #5
    Join Date
    Oct 2002
    Location
    Leicester - UK
    Posts
    820
    yeap that locks the computer as form 1 locks out form 2 while it keeps checking the variable and as form 2 is locked out it can't change the variable
    Definition of a Beginner, Someone who doesn't know the rules.

    Definition of an Expert, Someone who knows when to ignore the rules.

  6. #6
    Join Date
    Aug 2002
    Location
    Charlotte NC
    Posts
    665
    Originally posted by m.timoney
    yeap that locks the computer as form 1 locks out form 2 while it keeps checking the variable and as form 2 is locked out it can't change the variable
    give this a try


    (Q) From a form, I'm opening another form to get some infomation from users. Then after closing this popup form, I want to resume my code execution from Form1 normally. However, Access doesn't wait for the second form to close and instead continues executing code. How do I make Access wait till the second form is closed?

    (A) Open the second form modally. For example,
    Docmd.OpenForm "SomeForm", , , , ,acDialog


    jim

  7. #7
    Join Date
    Apr 2002
    Posts
    139
    Perhaps the Sleep command will be of any benefit to you?

    See the attached mdb (Access 97 with some Dutch lyrics...) for a demo of a 5 second brake. You can set this to be any time you like.

    hth
    Attached Files Attached Files

  8. #8
    Join Date
    Oct 2002
    Location
    Leicester - UK
    Posts
    820
    Originally posted by JDionne
    give this a try


    (Q) From a form, I'm opening another form to get some infomation from users. Then after closing this popup form, I want to resume my code execution from Form1 normally. However, Access doesn't wait for the second form to close and instead continues executing code. How do I make Access wait till the second form is closed?

    (A) Open the second form modally. For example,
    Docmd.OpenForm "SomeForm", , , , ,acDialog


    jim
    thanks thats got it, that must have been the only thing i hadn't tried
    Definition of a Beginner, Someone who doesn't know the rules.

    Definition of an Expert, Someone who knows when to ignore the rules.

  9. #9
    Join Date
    Aug 2002
    Location
    Charlotte NC
    Posts
    665
    Originally posted by m.timoney
    thanks thats got it, that must have been the only thing i hadn't tried
    Cool Glad it helped
    Jim

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •