| |
|
|
RGH | un Code-Schnipsel aus einem aktuell erstelltem Hilfsprogramm. Getestet sous Win XP SP 2.
' Bildschirmschoner un-/ausschalten
'Hintergrundfarbe des Desktops einstellen
'Hintergrundbild auswählen ou bien entfernen
'RGH 17.07.2008
$H windows.ph
' Screensaver un-/ausschalten
' -----------------------
' commutateur% - 1 = un / 0 = aus
proc setsaver
Paramètres commutateur%
si commutateur% = 0
WriteIni "HKEY_1","Control Panel\Desktop", "ScreenSaveActive" = "0"
WriteIni "HKEY_1","Software\Policies\Microsoft\Windows\Contrôle Panel\Desktop", "ScreenSaveActive" = "0"
d'autre
WriteIni "HKEY_1","Control Panel\Desktop", "ScreenSaveActive" = "1"
WriteIni "HKEY_1","Software\Policies\Microsoft\Windows\Contrôle Panel\Desktop", "ScreenSaveActive" = "1"
endif
endproc
'Hintergrundfarbe einstellen
' ---------------------------
' farbe& - RGB-Wert qui la couleur
proc setcolor
parameters farbe&
declare elem&[0], color&[0]
elem&[0] = ~COLOR_DESKTOP
color&[0] = farbe&
~SetSysColors(1, addr(elem&[0]), addr(color&[0]))
endproc
'Hintergrundbild einstellen
' ---------------------------
' bild$ - Dateiname zum Hintergrundbild
proc setpic
parameters bild$
si bild$ > »
WriteIni "HKEY_1","Control Panel\Desktop", "WallpaperStyle" = "3"
WriteIni "HKEY_1","Control Panel\Desktop", "TileWallpaper" = "2"
WriteIni "HKEY_1","Control Panel\Desktop", "Wallpaper" = bild$
~SystemParametersInfo(~SPI_SETDESKWALLPAPER, 0, addr(bild$), ~SPIF_SENDCHANGE)
d'autre Hintergrundbild ausschalten
WriteIni "HKEY_1","Control Panel\Desktop", "WallpaperStyle" = "0"
WriteIni "HKEY_1","Control Panel\Desktop", "TileWallpaper" = "0"
WriteIni "HKEY_1","Control Panel\Desktop", "Wallpaper" = »
~SystemParametersInfo(~SPI_SETDESKWALLPAPER, 0, addr(bild$), ~SPIF_SENDCHANGE)
endif
endproc
Salut Roland |
|
|
| Intel Duo E8400 3,0 GHz / 4 GB RAM / 1000 GB HDD - ATI Radeon HD 4770 512 MB - Windows 7 Home Premium 32Bit - XProfan X4 | 17.07.2008 ▲ |
|
|
|
|
| allô Roland, XPSE [...] meckerte "unbekannte Escapesequenz" dans
WriteIni "HKEY_1","Software\PoliciesMicrosoft\Windows\Contrôle Panel\Desktop", "ScreenSaveActive" = "0"
habe Deinen Code dessus dahingehend korrigiert.
Code funktioniert super! |
|
|
| |
|
|
|
RGH | iF
habe Deinen Code dessus dahingehend korrigiert.
merci!
Salut Roland |
|
|
| Intel Duo E8400 3,0 GHz / 4 GB RAM / 1000 GB HDD - ATI Radeon HD 4770 512 MB - Windows 7 Home Premium 32Bit - XProfan X4 | 17.07.2008 ▲ |
|
|
|