English
Source / code snippets

exchange Wallpapers windows

 

Source watts on the 15.07.2007 from the MMJ-Quellcodesammlung (Dietmar horn) in The Babyklappe on XProfan.Com stored:
windows-Wallpapers exchange
executable ex Profan-Version 5.0
PRFellow - Presentation
Author: Thomas Hölzer
Hintergrundbitmap for Desktop loading/take on/delete
example for usage of SystemParametersInfo
Parameter 1: must 20 his for The BMP-function
Parameter 2: must 0 his
Parameter 3: Pointer on String, the whom names the BMP contains
Parameter 4: $0003: entry becomes stored and entspr. Message gesendet
Return   : mismatched 0 with success
Declare pointer#
Def SetWallPaper(4) !USER32,SystemParametersInfoA
Image and Anzeigemodus settle

Proc SetWPBmp

    Parameters file$,tiled%
    Dim pointer#,256
    String pointer#,0=file$
    SetWallPaper(20,0,pointer#,$0003)
    Dispose pointer#
    WriteIni HKEY_1,Control Paneldesktop,WallPaper = file$
    so GEHTS of course too, but SystemParametersInfo is the better lane,
    especially since one it for SPI_SETWININICHANGE eh need
    WriteIni HKEY_1,Control Paneldesktop,TileWallpaper = Str $(tiled%)
    SetWallPaper(20,0,0,2) SPI_SENDWININICHANGE

ENDPROC

Wallpapers stretchen

Proc SetWPStyle

    Parameters style%
    WriteIni HKEY_1,Control Paneldesktop,WallPaperStyle = Str $(style%)
    SetWallPaper(20,0,0,2)

ENDPROC

example
Declare bmp$,end%
Window Title Wallpapers settle
Window 100,100-250,250
Pop &Wallpapers
AppendMenu 1, &BMP as Desktophintergrund (Centered)
AppendMenu 2, B&MP as Desktophintergrund (tiled)
Separator
AppendMenu 3, Wallpapers on &filled Bildschirmgröße stretchen
AppendMenu 4, &Standardgröße
Separator
AppendMenu 5,&Hintergrundbmp Remove
Separator
AppendMenu 6,&terminate

WhileNot end%

    IF Len(bmp$)

        LoadSizedBmp bmp$,0,0-250,250;0

    ENDIF

    WaitInput

    If MenuItem(1)

        Let bmp$=LoadFile $(Hintergrundbmp for Desktop,*.bmp)
        SetWPBmp bmp$,0

    ElseIf MenuItem(2)

        Let bmp$=Loadfile$(Hintergrundbmp for Desktop,*.bmp)
        SetWPBmp bmp$,1

    ElseIf MenuItem(3)

        SetWPStyle 2

    ElseIf MenuItem(4)

        SetWPStyle 0

    ElseIf MenuItem(5)

        SetWPBmp ,0
        Let bmp$=
        Cls

    Elseif MenuItem(6)

        Let end%=1

    Elseif MenuItem(254)

        MessageBox(Author: Thomas Hölzer,PRFellow-Presentation,64)

    EndIf

Wend

End
 
07/15/07  
 



Zum Quelltext


Topictitle, max. 100 characters.
 

Systemprofile:

no Systemprofil laid out. [anlegen]

XProfan:

 Posting  Font  Smilies  ▼ 

Please register circa a Posting To verfassen.
 

Topic-Options

2.220 Views

Untitledvor 0 min.
Sven Bader07/03/23
Michaeal04/09/14
Tommy02/01/13
Klaus Ernst01/12/11

Themeninformationen

this Topic has 1 subscriber:

unbekannt (1x)


Admins  |  AGB  |  Applications  |  Authors  |  Chat  |  Privacy Policy  |  Download  |  Entrance  |  Help  |  Merchantportal  |  Imprint  |  Mart  |  Interfaces  |  SDK  |  Services  |  Games  |  Search  |  Support

One proposition all XProfan, The there's!


My XProfan
Private Messages
Own Storage Forum
Topics-Remember-List
Own Posts
Own Topics
Clipboard
Log off
 Deutsch English Français Español Italia
Translations

Privacy Policy


we use Cookies only as Session-Cookies because of the technical necessity and with us there no Cookies of Drittanbietern.

If you here on our Website click or navigate, stimmst You ours registration of Information in our Cookies on XProfan.Net To.

further Information To our Cookies and moreover, How You The control above keep, find You in ours nachfolgenden Datenschutzerklärung.


all rightDatenschutzerklärung
i want none Cookie