dItem "None"
End With
With cboDisplay
.AddItem "Center"
.AddItem "Tiled"
.AddItem "Stretch"
End With
Dim sWallpaper As String
sWallpaper = Reg_Read(HKEY_CURRENT_USER, "Control Panel\Desktop", "Wallpaper")
If sWallpaper <> vbNullString Then
lstNewWallpaper.AddItem sWallpaper
lstNewWallpaper.Selected(lstNewWallpaper.NewIndex) = True
txtCurrent.Text = sWallpaper
End If
Dim lReturn As Long
lReturn = Reg_Read(HKEY_CURRENT_USER, "Control Panel\Desktop", "WallpaperStyle")
Select Case lReturn
Case 0 To 2: cboDisplay.ListIndex = lReturn
Case Else: cboDisplay.ListIndex = 0
End Select
Exit Sub
VB_Error:
Call Error_VB(Err, sLocation & "\Form_Load")
Resume Next
End Sub
Private Sub lstNewWallpaper_Click()
On Error GoTo VB_Error
imgPreview.Picture = Nothing
If lstNewWallpaper.ListIndex > 1 Then
If File_Exist(lstNewWallpaper.List(lstNewWallpaper.ListIndex)) = True Then
imgPreview.Picture = LoadPicture(lstNewWallpaper.List(lstNewWallpaper.ListIndex))
End If
End If
Exit Sub
VB_Error:
Call Error_VB(Err, sLocation & "\lstNewWallpaper_Click")
Resume Next
End Sub