I'm begginer at VBA. What should be the correct way to check if a display is currently showing and then show another display?
I tried to put this code on two main displays "display1" and "display2":
Private Sub Display_AnimationStart()
ShowDisplay ("bannerA")
End Sub
Private Sub Display_AfterAnimationStop()
ShowDisplay ("bannerB")
End Sub
This works when start, display1 or display2, or when I change from them to another display (to display99 for example).
But when I change from display 1 to display 2 , it shows "bannerB" replacing "bannerA", when it should keep "bannerA" in this case.
It seems that sub Display_AfterAnimationStop of the closing display executes after Display_AnimationStart of the opening display(which is strange).
I tried BeforeAnimationStop and same thing happens.
I don't want to use "pause", because banner B would show quickly before displaying banner A. What I want is:
- When I change between display1 and display2, it keeps banner A.
- When I change from display1 or display2 to any other main display, it changes from bannerA to bannerB.
- When I change from any other main display to display1 or display2, it changes from bannerB to bannerA.
- Use the working VBA command only on display1 and display2.
Thank you!
I tried to put this code on two main displays "display1" and "display2":
Private Sub Display_AnimationStart()
ShowDisplay ("bannerA")
End Sub
Private Sub Display_AfterAnimationStop()
ShowDisplay ("bannerB")
End Sub
This works when start, display1 or display2, or when I change from them to another display (to display99 for example).
But when I change from display 1 to display 2 , it shows "bannerB" replacing "bannerA", when it should keep "bannerA" in this case.
It seems that sub Display_AfterAnimationStop of the closing display executes after Display_AnimationStart of the opening display(which is strange).
I tried BeforeAnimationStop and same thing happens.
I don't want to use "pause", because banner B would show quickly before displaying banner A. What I want is:
- When I change between display1 and display2, it keeps banner A.
- When I change from display1 or display2 to any other main display, it changes from bannerA to bannerB.
- When I change from any other main display to display1 or display2, it changes from bannerB to bannerA.
- Use the working VBA command only on display1 and display2.
Thank you!