|
|
|
![]() |
|
Strumenti |
![]() |
#1 |
Senior Member
Iscritto dal: Mar 2006
Città: Milano
Messaggi: 832
|
[C#] immagine di sfondo per form da file.
ciao ragazzi..
per mettere un immagine di sfondo nella form ho trovato questo codice Codice:
assembly asm = Assembly.GetExecutingAssembly(); bitmap backgroundImage = new Bitmap(asm.GetManifestResourceStream("image.bmp")); e.Graphics.DrawImage(backgroundImage, this.ClientRectangle, new Rectangle(0, 0, backgroundImage.Width, backgroundImage.Height), GraphicsUnit.Pixel); come posso fare? grazie! ah dimenticavo niente metodo form.backgroundimage perchè non c'è su WM ![]() Ultima modifica di nikel : 02-03-2010 alle 14:50. |
![]() |
![]() |
![]() |
#2 |
Senior Member
Iscritto dal: Mar 2006
Città: Milano
Messaggi: 832
|
Non funziona nemmeno così
Codice:
bitmap backgroundImage; //nel paint backgroundImage = new Bitmap("image.bmp"); e.Graphics.DrawImage(backgroundImage, this.ClientRectangle, new Rectangle(0, 0, backgroundImage.Width, backgroundImage.Height), GraphicsUnit.Pixel); |
![]() |
![]() |
![]() |
Strumenti | |
|
|
Tutti gli orari sono GMT +1. Ora sono le: 18:02.