Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people, just like you, are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
Solved

Wallpaper

Posted on 1997-12-02
8
1,009 Views
Last Modified: 2013-12-03
I know how to change wallpaper by win32 call SystemParametersInfo with SPI_SETDESKWALLPAPER as paramater. Can I also change background pattern and display (tile or center) by any function call? Or are there any other methods that I can change these settings without using control panel's "Display" program. In other word, can I change these settings winthin my program? Many thanks!  
0
Comment
Question by:pai
8 Comments
 
LVL 1

Expert Comment

by:2good
ID: 1409065
In Windows 95, this information is stored both in the [Desktop] section in WIN.INI and in the registry under the HKEY_CURRENT_USER\Control Panel\desktop key. I am not sure which one is superior the other.

Wallpaper=C:\WINDOWS\NETSCAPE.BMP
TileWallpaper=1
Pattern=254 2 250 138 186 162 190 128

"Wallpaper" is the name of a bitmap file
If none is selected, the value is empty in the registry and "(none)" in WIN.INI. (Without quotation marks.)

"TileWallpaper" is a string boolean telling if to tile (1) or center (0)

"Pattern" is eight space-separated byte values (0-255) of the bit mask for the pattern

If you modify the TileWallpaper value, the setting will probably be updated when you call SystemParametersInfo with SPI_SETDESKWALLPAPER.
According to system documentation you can also use SPI_SETDESKPATTERN to modify the Pattern section.

0
 
LVL 11

Expert Comment

by:mikeblas
ID: 1409066
Don't modify the registry directly when there are APIs that do what you want.  Instead of changing the registry, use the IActiveDesktop interface.

.B ekiM

0
 

Author Comment

by:pai
ID: 1409067
Where can I find IActiveDesktop? And where can I find the documentation for that? I use VC++ 4.0, and I can not find it. I intend to use it in Windows 95. Thanks!
0
Networking for the Cloud Era

Join Microsoft and Riverbed for a discussion and demonstration of enhancements to SteelConnect:
-One-click orchestration and cloud connectivity in Azure environments
-Tight integration of SD-WAN and WAN optimization capabilities
-Scalability and resiliency equal to a data center

 

Author Comment

by:pai
ID: 1409068
To 2good,

I'm satisfied by your answer. Please answer the question, so I can give you credits.

pai
0
 
LVL 11

Accepted Solution

by:
mikeblas earned 100 total points
ID: 1409069
The IActiveDeskotp interface is documented in the Platform SDK, which is included in MSDN. It's also downloadable from http://www.microsoft.com/, and I think it's available online at http://www.microsoft.com/msdn/ in the Preimum Content area.

.B ekiM

0
 
LVL 10

Expert Comment

by:RONSLOW
ID: 1409070
What version of Win95 and/or WinNT supports IActiveDesktop?

From its name it sounds like an IE4/Win98 extension...

0
 

Author Comment

by:pai
ID: 1409071
ya! I have trouble to find out how IActiveDestop works in regular Windows 95. Could mikeblas give us a little bit more explanation?

0
 
LVL 1

Expert Comment

by:tiago
ID: 1409072
Try overriding the Desktop Window WindowProc function
0

Featured Post

Free Tool: Subnet Calculator

The subnet calculator helps you design networks by taking an IP address and network mask and returning information such as network, broadcast address, and host range.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

This article shows how to make a Windows 7 gadget that extends its U/I with a flyout panel -- a window that pops out next to the gadget.  The example gadget shows several additional techniques:  How to automatically resize a gadget or flyout panel t…
For a while now I'v been searching for a circular progress control, much like the one you get when first starting your Silverlight application. I found a couple that were written in WPF and there were a few written in Silverlight, but all appeared o…
This is Part 3 in a 3-part series on Experts Exchange to discuss error handling in VBA code written for Excel. Part 1 of this series discussed basic error handling code using VBA. http://www.experts-exchange.com/videos/1478/Excel-Error-Handlin…
I've attached the XLSM Excel spreadsheet I used in the video and also text files containing the macros used below. https://filedb.experts-exchange.com/incoming/2017/03_w12/1151775/Permutations.txt https://filedb.experts-exchange.com/incoming/201…

838 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question