ccondran08
Registered User.
- Local time
- Tomorrow, 03:40
- Joined
- Feb 27, 2014
- Messages
- 58
Hi, I have a problem whereby I have created Form1 with a button and after I click the button Form2 appears (frm_Rollover_Progress). Form2 is a (poor man’s) progress indicator that makes some labels visible after a section of a query has run. I have set the first label on the form to ‘Me.lblProgress1.Visible = True’ but I keep coming up with ‘Compile Error - Method or data member not found’. However, when I put a button on the second form and copy in the exact same code then ‘Me.Label1.Visible = True’ works. I have tried to SetFocus to an item on Form2 but still does not work. Below is part of the code. Does anyone have any suggestions?
'Open progress form to show progress indicator
DoCmd.OpenForm "frm_Rollover_Progress", acNormal, , , acFormReadOnly
'Add current changes to Total Changes table
Me.lblProgress1.Visible = True
Me.Label1.Caption = "10%"
DoCmd.OpenQuery "qry_Change_AddedQX2", acViewNormal, acAdd
Me.lblProgress2.Visible = True
Me.lblProgress3.Visible = True
Me.Label1.Caption = "30%"
'Open progress form to show progress indicator
DoCmd.OpenForm "frm_Rollover_Progress", acNormal, , , acFormReadOnly
'Add current changes to Total Changes table
Me.lblProgress1.Visible = True
Me.Label1.Caption = "10%"
DoCmd.OpenQuery "qry_Change_AddedQX2", acViewNormal, acAdd
Me.lblProgress2.Visible = True
Me.lblProgress3.Visible = True
Me.Label1.Caption = "30%"