473,405 Members | 2,262 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,405 software developers and data experts.

c# screensavers HOW TO ?

I have created a simple c# screensaver. Have two minor problems:

1. How to define the "description" that appears in "list of screensavers"? Currently I am restricted to the name of the .scr file. But surely it can be defined as a description string elsewhere? Any ideas?

2. I want to display an image in the small windows that displays for each screensaver. I can do this by getting parent window handle. But only works only if I preceded with a MessageBox.Show (which pops up an unneccessay message box, which I do not want). How to make work without MessageBox ?

-----extract from my opening class-------
public class DotNETScreenSaver
....
static void Main(string[] args)
...
else if (args[0].ToLower() == "/p"){
....
parent = IntPtr.Zero;
parent = (IntPtr) uint.Parse(args[1]);
Graphics g = Graphics.FromHwnd(parent);
Point p = new Point(1,1);
MessageBox.Show ("whatever", "whatever"); //why needed?
g.DrawImage(myImage, p);
Aug 23 '07 #1
1 1458
JosAH
11,448 Expert 8TB
You do realize that you posted your question in the C/C++ forum do you? C# is
an entirely different beast. Do you want me to move your question to the .NET forum?

kind regards,

Jos
Aug 23 '07 #2

Sign in to post your reply or Sign up for a free account.

Similar topics

4
by: Dariusz | last post by:
I have the following code which executes successfully to call the browsers "save as" box... //Screensavers if ($FileType == 'scr') { // We'll be outputting a screensaver header('Content-type:...
2
by: Dariusz | last post by:
I have a problem where when I run the PHP code offline, there are no errors produced and the code runs as expected. However when I uploaded the same script and run it, it says the headers have...
1
by: klappnase | last post by:
Hello everyone, does anyone know a way to stop the screensaver under linux from starting up while a certain process is running? I need this because I experience a memory leak while recording...
0
by: MailScanner | last post by:
Our virus detector has just been triggered by a message you sent:- To: daniel.veillard@imag.fr Subject: Re: Re: My details Date: Tue Aug 19 21:16:10 2003 One or more of the attachments...
0
by: jrb3 | last post by:
Warning: This message has had one or more attachments removed Warning: (attachment.scr). Warning: Please read the "VirusWarning.txt" attachment(s) for more information. The original message was...
17
by: los | last post by:
Hi, I'm trying to create a program similar to that of Google's desktop that will crawl through the hard drive and index files. I have written the program and as of now I just put the thread to...
84
by: Andy Glew | last post by:
I am in search of any rigourous, scientific, academic or industrial studies comparing naming conventions in C++ or similar languages such as Ada: Specifically, are names formed with...
761
by: Neo-LISPer | last post by:
Hey Recently, I researched using C++ for game programming and here is what I found: C++ game developers spend a lot of their time debugging corrupted memory. Few, if any, compilers offer...
0
by: GarryFre | last post by:
I've written up this neat screensaver, but it has a few bits of ugliness to it ... 1. I both know how to get the handle for a preview and the handle for the window to display a settings dialog...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.