I have a somwhat complex interface using a Tabbed control and, within the pages, some subforms,
One of the subforms is hidden and holds specific user information on a multi user setup.
I am not getting it to work because I am not able to make sure that this form (F91) is loaded before some of the others. Actually, on the main tab code, on the first Form that I am opening,, the first thing I am doing is to issue a DoCmd to Open the form.
So I think that I should arrange a manner of guaranteeing that F91 is preloaded and should have a test to check if a form is already loaded or not in order to avoid sistematic crashes
how do I do it?
Private Sub Form_Load()
Dim IBool As Boolean
<'---------- CRASH even before this point as some of the other forms and code refers to F91 which Opened after
Me.F00_UserName = Null
Me.F00_UserName.Locked = True
Me.F00_UserPassword = Null
Me.F00_UserPassword.Locked = True
DoCmd.OpenForm "F91_LoggedUser", , , , , acHidden
IBool = InsertLog("CDI Start", "F00 Load", "", "", "", 0, 0, "##NA##", "")
Forms![F91_LoggedUser]![F0001_Field] = "F0001_DiasFaltam"
Forms![F91_LoggedUser]![F0001_FieldState] = "UP" ' todos os outros campos serão nulos