| | |
Program to change desktop background
Please support our C++ advertiser: Intel Parallel Studio Home
![]() |
•
•
Join Date: May 2004
Posts: 217
Reputation:
Solved Threads: 0
Hi everyone. I heard that it is possible to code up a small program to randomly change windows desktop bg pic. I havent got any code (as i dont know how to do it) so could some plz tell me, or direct me to a site or something. Btw this isnt homework, just something im curious about!
many thx in advance
many thx in advance
•
•
Join Date: Mar 2004
Posts: 1,620
Reputation:
Solved Threads: 51
Hello,
I would guess that this is handled by the Windows Registry. You can make what is called a .reg file that inserts information into the registry. You could write a C++ code to prompt the user the desktop options, and then have the C++ program make the registry edit. You would also need to specify if you want the current user to only receive the edit, or the whole bunch.
Do a search on Windows Desktop Registry. See what you find.
Christian
I would guess that this is handled by the Windows Registry. You can make what is called a .reg file that inserts information into the registry. You could write a C++ code to prompt the user the desktop options, and then have the C++ program make the registry edit. You would also need to specify if you want the current user to only receive the edit, or the whole bunch.
Do a search on Windows Desktop Registry. See what you find.
Christian
Actually you can do this programatically fairly easily...
Using Windows API's SystemParametersInfo with SPI_SETDESKWALLPAPER.
http://msdn.microsoft.com/library/de...metersinfo.asp
I don't program in Win32 anymore, so the if you get stuck try looking here:
http://www.c-sharpcorner.com/Code/20...eWallpaper.asp
You should be able to figure out which constants correspond to the given values in the example.
Have fun!
Ed
Using Windows API's SystemParametersInfo with SPI_SETDESKWALLPAPER.
http://msdn.microsoft.com/library/de...metersinfo.asp
I don't program in Win32 anymore, so the if you get stuck try looking here:
http://www.c-sharpcorner.com/Code/20...eWallpaper.asp
You should be able to figure out which constants correspond to the given values in the example.
Have fun!
Ed
![]() |
Similar Threads
- Can't change desktop background - NOT the usual problem (Windows NT / 2000 / XP)
- Desktop background won't change - Hijack Log Provided (Viruses, Spyware and other Nasties)
- Cannot change desktop background (Viruses, Spyware and other Nasties)
- windows xp desktop background problem (Viruses, Spyware and other Nasties)
- Desktop background locked out (Viruses, Spyware and other Nasties)
Other Threads in the C++ Forum
- Previous Thread: Help with "operators overloading"
- Next Thread: Reading string with spaces frm file
| Thread Tools | Search this Thread |
api array arrays based beginner binary bitmap c++ c/c++ calculator char char* class classes coding compile compiler console conversion count data database delete deploy desktop developer directshow dll dynamiccharacterarray email encryption error file forms fstream function functions game getline google graph homeworkhelp homeworkhelper iamthwee ifstream input int integer lib linkedlist linux list loop looping loops map math matrix memory multiple news node number numbertoword output parameter pointer problem program programming project proxy python random read recursion recursive reference return rpg sorting string strings struct template templates text tree unix url vector video visual visualstudio win32 windows winsock word wordfrequency wxwidgets






