Replacing Text On-Page for Interactive Book

I too am working on creating an interactive book, and the page flip has been extremely helpful. However, I'm having a problem getting the science behind touching a certain object, having new text replace old text on the same layout/page without creating a new page for each instance.
Would anyone have a tip? I've tried setting it up as a "Destroy" Rule, but it's not jiving.
Thanks,
Imaginativelane
Would anyone have a tip? I've tried setting it up as a "Destroy" Rule, but it's not jiving.
Thanks,
Imaginativelane
Comments
Basically I made a game attribute (integer) which I called 'Page #' and set the default # to '1'. Then I made back/forward buttons (actors) on my page to cycle through the pages. When you click the back actor: change (game.page#) attribute to (game.page#) - 1. For forward: change to (game.page# + 1).
Then I had rules and 'display text' behaviours for each page, eg: When (attribute) (game.page#) = 1, Display text (page 1 text here). When (attribute) (game.page#) = 2 Display text (page 2 text here) etc etc. That way you can cycle through different pages of text without changing scene!
Also make sure that you add rules on the buttons so the (game.page#) value is constrained from 1 to whatever number of pages you have.
I hope this helps! Let me know if you need me to clarify any further. There may be a much easier way but this was my solution and it worked well for me.