So, I’m writing a small macro in Base that triggers with the event Open Document on the Form level. The thing is this event triggers when I open in normal mode and in edit mode. So, I would like to know in basic when it is in normal mode. Is there some form property that allows my code to know this? Thanks.
Hello,
Appears you want to bypass code execution if editing. For that:
Rem If Design mode, just exit the routine and display standard menu
xCurrentController = thisComponent.CurrentController
If xCurrentController.isFormDesignMode Then
Exit Sub
End If
Place at the beginning of your routine.
1 Like
Well, that gave me a method not found error.
I used:
set myForm = Application.AllForms("UpdateReportNumbers")
xCurrentController = myForm.CurrentController 'errored on this line.
Not the code presented. Code posted is what I use in my aps. Works without problems.