I have the following (pseudo-)code:
public publVar
Sub
publVar = ""
OpenForm Form1
Do until publVar <> ""
Sleep 100
DoEvents
Loop
'Do Something with publVar
End Sub
It is supposed to stop the execution of the code until a value is assigned to publVar on Form1. There is the option to assign the attribute "Popup" to a form in Access to prevent code from being executed but that didnt work for me. My Question is: Is there a better way to do this in Access?