Results 1 to 2 of 2
  1. #1
    2 Star Lounger
    Join Date
    Nov 2004
    Location
    Lexington Park, Maryland, USA
    Posts
    119
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Detecting when a form is closed or opened (Access 2000)

    I need a piece of VBA to let me know if another form in Access is open or closed.

    I hope that is enough info. Its a pretty straight forward piece of code, I know. But today is turning out to be a very bad brain day for Mike.

    Thanks
    Mike

  2. #2
    Silver Lounger
    Join Date
    Jun 2001
    Location
    Niagara Falls, New York, USA
    Posts
    1,878
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Detecting when a form is closed or opened (Access 2000)

    Try

    Put this in module

    Function IsLoaded(FormName)
    IsLoaded = (SysCmd(acSysCmdGetObjectState, acForm, FormName) <> 0)
    End Function


    Put this in form or report

    If IsLoaded("frm_Permit_Eng_ACD") Then

    End If

    HTH, John

Posting Permissions

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