You are still calling the public procedure from outside of the containing form. ?
And switching to design view should fire the close and unload events. I haven't tested it but I would expect that to cancel any loop (of course a loop will lock the form unless you've used doevents and that would be a design rather than a user issue).
I'm not seeing a real world problem here. I'd be interested if you do have an example.
Thank you, I will explore this today! I appreciate your quick responses. I will definitely explore the Forms collection link you posted. I will play with the replacement of Me.
No, actually I wasn't calling from outside of the containing form yet. Was first attempting to understand the workings of the code, not sure I understand how to call the form when I tried it the first time. I then attempted to see if I could get any type of result in the Navigation form I am inspecting, and I did, which is very optimistic:When this loop runs, it displays ever-increasing numbers in the Immediate window, each number followed by the value of CurrentView. In addition, there needs to be a non-form module with this code:
Sub LoopTest()
Form_Form1.BigLoop
End Sub
Below code is in Maintenance Form that I'm not sure about which opens before the Navigation Form (Loop Code) that I am testing to see if is switched to Design View.
Sub LoopTest()
Form_NavigationF.BigLoop or Form!NavigationF.BigLoop
End Sub
I will try it properly was trying to get an understanding first but probably sabotaged myself doing so...
And also, I don't need a repetitive loop per se just a one time notification of the event.
If I get this working I will then write a procedure to send me an email in real-time when this occurs