![]() |
|
![]() |
|
|
Thread Tools | Display Modes |
|
|
#1 |
|
Newbie
Join Date: Oct 2004
Posts: 1
Rep Power: 0
![]() |
How do I script a button to change the background image of a form?
I've tried //formMainMenu.set_BackgroundImage(System.Drawing.Image)(resources.getFromFile("mydocs\Project\GameOver800")); With GameOver800 being the image name. I've also tried GameOver800.jpg but that does not work. |
|
|
|
|
|
#2 |
|
Expert Programmer
|
Probably easier to plug in a littl bit of javascript here since if I recall correctly C# will reload your page on your to make that change. Here is an example of changing it for a whole page:
<html> <div id="1"><body bg=1.jpg></div> <input type=button value=whatever onClick="document.GetElementByID( '1' ).innerHTML = '<body bg=2.jpg>';"> </body> </html> Get the idea?
__________________
Clifford Matthew Roche <geek@cliffordroche.com> Web Hosting: http://www.crd-hosting.com Consulting: http://www.crdev-consulting.com |
|
|
|
![]() |
| Bookmarks |
| Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
| Thread Tools | |
| Display Modes | |
|
|