Bonjour,
Je débute en ce qui concerne les API et j'ai un problème en ce qui concerne le code précédent.
Pas de changement du fond d'écran, mais la possibilité de l'effacer en promenant la fenetre du projet ;-)
Dans la procédure du bouton, faut-il utiliser "SystemParametersInfo..." ou "'Change_Wallpaper"
Merci d'avance pour la réponse.
XToff 
Voila ce que j'ai :
-----------------------------------------------
Imports System.Runtime.InteropServices
Public Class Form1
Inherits System.Windows.Forms.Form
#Region " Code généré par le Concepteur Windows Form "
' Je n'ai evidemment pas copié ce qui précède
Declare Auto Function SystemParametersInfo Lib "user32.dll" Alias "SystemParametersInfoA" ( _
ByVal uAction As Integer, _
ByVal uParam As Integer, _
ByVal lpvParam As String, _
ByVal fuWinIni As Integer) As Integer
Private Const SPI_SETDESKWALLPAPER As Integer = 20
Private Const SPIF_UPDATEINIFILE As Integer = 1
Private Const SPIF_SENDWININICHANGE As Integer = &H2
Dim fichier As String
<DllImport("User32.dll", EntryPoint:="SystemParametersInfo", _
SetLastError:=True, CharSet:=CharSet.Auto, _
CallingConvention:=CallingConvention.StdCall)> _
Public Shared Function Change_Wallpaper(ByVal uiAction As Integer, _
ByVal uiParam As Integer, ByRef pvParam As String, ByVal fWinIni As Integer)
End Function
Private Sub Button1_Click( _
ByVal sender As System.Object, _
ByVal e As System.EventArgs) _
Handles Button1.Click
fichier = "D:\Wallpaper1.bmp"
'Change_Wallpaper(SPI_SETDESKWALLPAPER, 0, fichier, SPIF_UPDATEINIFILE Or SPIF_SENDWININICHANGE)
SystemParametersInfo(SPI_SETDESKWALLPAPER, 0, fichier, SPIF_UPDATEINIFILE Or SPIF_SENDWININICHANGE)
End Sub
End Class
---------------------------------------