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!

SPIF_SENDCHANGE

Status
Not open for further replies.

capone67

Programmer
Nov 6, 2000
115
0
0
CA
Hi Gang

I am trying to use SPIF_SENDCHANGE to case my windows desktop to refresh in win98. I dont really know what the value of this constant is but I think it is supposed to be 2. When I run my code the value returned is 'Empty'. Here are the relevant lines of code that I have.

Private Declare Function SystemParametersInfo Lib "user32" Alias _
"SystemParametersInfoA" (ByVal uAction As Long, ByVal uParam As Long, _
ByVal lpvParam As String, ByVal fuWinIni As Long) As Long

errorlocation = SetKeyValue(HKEY_CURRENT_USER, "Software\Microsoft\Internet Explorer\Desktop\General\", "Wallpaper", "C:\wallpaper\" & FileName & ".jpg", REG_SZ)

errorlocation = SystemParametersInfo(SPI_SETDESKWALLPAPER, 0, "C:\wallpaper\" & FileName & ".jpg", SPIF_SENDCHANGE)

I know that the SetKeyValue is functioning properly, whne I right click the resktop and click refresh, the wallpaper changes.

Any ideas on what I am doing wrong would be greatly appreiciated.

Ken

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top