Slide Show

I used the example shown above to change display. However, the swapwindow() method did not work. It did not clear the old windows from the display. The new windows showed up to the right of old window. I had three windows in my project. After two timer intervals, all three windows were showing on the screen. So, I ended up using the function calls closewindow/openwindow. Is there any window property that needs to be set to make the swapwindow() method work.