Seite 1 von 1

Hintergrundbild

Verfasst: 29.10.2004 19:05
von KeyKon
Wie kann man mit einem Programm ein Bild als Hintergrundbild (Desktop) einstellen, muss das irgendwo hinkopiert werden oder gibt es einen Befehl dafür oder geht das gar nicht???

KeyKon

Verfasst: 29.10.2004 19:10
von nco2k
WinAPI beispiel aus dem CodeArchiv:

Code: Alles auswählen

; English forum: http://purebasic.myforums.net/viewtopic.php?t=6698&highlight=
; Author: ebs
; Date: 24. June 2003

; Changes background image of Windows desktop
Procedure SetWallpaper(FileName.s) 
  SystemParametersInfo_(#SPI_SETDESKWALLPAPER, 0, FileName, #SPIF_UPDATEINIFILE | #SPIF_SENDWININICHANGE) 
EndProcedure 

WPFileName.s = OpenFileRequester("Select Wallpaper image", "*.bmp", "Bitmap Files (*.bmp)|*.bmp|All Files (*.*)|*.*", 1, 0) 
If WPFileName <> "" 
  SetWallpaper(WPFileName) 
EndIf 

; ExecutableFormat=Windows
; CursorPosition=4
; FirstLine=1
; EOF
c ya,
nco2k

Verfasst: 29.10.2004 23:02
von KeyKon
Danke :)