View Full Version : one button to change back ground pics
Bruce
04-18-2003, 08:36 PM
I know this has past through here before but... What I want to do is change the background pics with a press of one button. I have ten pics to use. Where did I see this?
Corey
04-18-2003, 10:13 PM
You want to change the background pic of your page at design time or run time?
Corey Milner
Creative Director, Indigo Rose Software (http://www.indigorose.com)
Bruce
04-18-2003, 11:09 PM
Run time, sorry.
Everyone dance!
Corey
04-18-2003, 11:39 PM
No way I know of to do that other than using an HTML or Flash object... You could always create ten pages each with a different background and then just switch between them at runtime I guess...
Corey Milner
Creative Director, Indigo Rose Software (http://www.indigorose.com)
Bruce
04-19-2003, 12:38 AM
Poop! Thats the way I had it before... ok thanks Corey. Oh b.t.w. When can I get a set of your CDs?
Corey
04-19-2003, 12:58 AM
At this point I can't make any predictions. I probably never should have been talking about it in the first place, my bad, lesson learned... /ubbthreads/images/icons/smile.gif
Corey Milner
Creative Director, Indigo Rose Software (http://www.indigorose.com)
Lorne
04-21-2003, 09:59 AM
You could also use a bunch of different image objects, stretched to the same size as the page, and just show/hide them appropriately.
Bruce
04-21-2003, 10:32 AM
See Lorne thats what I thought... But I wasn't sure how to employ that into one button.
Lorne
04-21-2003, 11:37 AM
Just use a variable as a counter -- each time the user clicks on the button, it increases by 1. When you get to 10, set it back to 0.
Then add a bunch of IF statements to check the value in that counter, and show/hide the appropriate images.
Another way to do it would be to name the image objects with numbers, like bg1, bg2, bg3, etc. and then just use the counter variable in the name of the object you want to show: i.e., hide all of the image objects, and then show the object named bg%i% (assuming your counter was called %i% -- you can call it anything you want, of course).
Jumping to 10 different pages would work fine, too...it just means having more pages to maintain.
Powered by vBulletin™ Version 4.0.6 Copyright © 2012 vBulletin Solutions, Inc. All rights reserved.