I have a form (Form A) that has a print command button - the resulting report takes about 3 to 5 seconds to open.
To notify the user, I developed a form (Form B) and code to animate a "Your Report is Being Generated" display (there are 4 dots that move across the form.) This is the only purpose of this Form B - it is closed when the calling procedure (located on Form A) completes.
The code on Form B works perfectly when I open the form on it's own (all animation is perfect) however, when the form is opened from Form A, everything works fine however, Form B is not animated (it is just a static image.)
Simplified code example is below:
I excluded the code Form B (all located in the Form Time event) as it seems to work well but I can share this if needed as well.
Thanks in advance for any assistance.
Gunner
[IMGNOTHUMB]https://bytes.com/attachments/attachment/9303d1514835264/form-logo-removed-.jpg[/IMGNOTHUMB][IMGNOTHUMB]https://bytes.com/attachments/attachment/9304d1514835264/form-b-logo-removed-.png[/IMGNOTHUMB]
To notify the user, I developed a form (Form B) and code to animate a "Your Report is Being Generated" display (there are 4 dots that move across the form.) This is the only purpose of this Form B - it is closed when the calling procedure (located on Form A) completes.
The code on Form B works perfectly when I open the form on it's own (all animation is perfect) however, when the form is opened from Form A, everything works fine however, Form B is not animated (it is just a static image.)
Simplified code example is below:
Code:
‘Hides Form A (Calling Form)
Me.Visible = False
‘Opens Form B (“Your Report is Being Generated” Form with Animation)
DoCmd.OpenForm "FormB"
DoEvents
DoCmd.OpenReport "rptSaleOrderPrintOut_Portrait", acViewReport
With Reports!rptSaleOrderPrintOut_Portrait.Report
.Filter = Nz(Me.sfrmSaleOrderSearch.Form.Filter, "*")
.FilterOn = IIf(Nz(Me.sfrmSaleOrderSearch.Form.Filter, "") = "", False, True)
End With
DoCmd.Close acForm, "FormB"
Thanks in advance for any assistance.
Gunner
[IMGNOTHUMB]https://bytes.com/attachments/attachment/9303d1514835264/form-logo-removed-.jpg[/IMGNOTHUMB][IMGNOTHUMB]https://bytes.com/attachments/attachment/9304d1514835264/form-b-logo-removed-.png[/IMGNOTHUMB]
Comment