IsFormLoaded name

lmcc007

Registered User.
Local time
Today, 00:06
Joined
Nov 10, 2007
Messages
635
Is there way to paste the name of the form automatically in code?

Below is the code I am using:

Code:
On Error GoTo ErrorHandler
    
    ' Make sure fdlgEventDetail is open
    If Not IsFormLoaded("fdlgEventDetail") Then
        MsgBox "This form ""fdlgEventNote"" cannot be open from the Navigation pane.", _
            vbInformation + vbOKOnly, gstrAppTitle
        Cancel = True
    End If
    

CleanUpAndExit:
    Exit Sub

ErrorHandler:
    Call MsgBox("An error was encountered" & vbCrLf & _
        vbCrLf & _
        "Description:  " & Err.Description & vbCrLf & _
        "Error Number:  " & Err.Number, , "Error")
    Resume CleanUpAndExit

Instead of me typing the form name, I would like the computer provide it automatically.
 

Users who are viewing this thread

Back
Top Bottom