Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Can ACCESS change Desktop Background

Status
Not open for further replies.

CLee

Programmer
Jan 28, 2001
14
0
0
AU
Can MS Access (VBA) be used to change the MS Windows NT/95/98 Desktop Background? Is how?
 
Private Declare Function SystemParametersInfo Lib "user32" Alias "SystemParametersInfoA" (ByVal uAction As Long, ByVal uParam As Long, ByVal lpvParam As Any, ByVal fuWinIni As Long) As Long
Public Const SPI_SETDESKWALLPAPER = 20
'**************************************
' Name: Change Wallpaper
' Description:This code changes Windows
' Wallpaper
' By: Greg G
'
'This code is copyrighted and has' limited warranties.Please see ' ww.Planet-Source-Code.com/xq/ASP/txtCode
' Id.2008/lngWId.1/qx/vb/scripts/ShowCode.
' htm'for details.'**************************************

Dim lngSuccess As Long
Dim strBitmapImage As String
strBitmapImage = "c:\windows\straw.bmp"
lngSuccess = SystemParametersInfo(SPI_SETDESKWALLPAPER, 0, strBitmapImage, 0)
 
I must be dumb. I just cant get this to work in Access. More help please.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top