Bug in Framework: Activate Event

A

Axel Dahmen

Hi,

I've noticed an error in the Activate event of .NET Framework 1.0/1.1: When
a .NET program starts but the window is opened behind other windows and thus
is NOT activated, the Activate event still is fired. So the program can not
recognize if it is active or not.

Can someone reproduce this behaviour? Or am I missing something?

TIA,
Axel Dahmen


PS: To have my test program start behind other windows, I've simulated
program loading by delaying form load:


[STAThread]
static void Main()
{
Thread.Sleep(3000);
Application.Run(new Form1());
}

private void Form1_Activated(object sender, System.EventArgs e)
{
lb.Items.Add("Activated");
}
 
A

Axel Dahmen

I've filed this as bug #FDBK33723 into MSDN Product Feedback Center.

Microsoft has confirmed this to be a bug in 1.0 and 1.1. They won't fix it
for 2.0 as it would break existing programs.

Still this bug is serious. There is no workaround possible.

Their answer still leaves the main question open: How is a program supposed
to recognize that it *isn't* active?

IMHO, fixing this bug is more important than being afraid of breaking any
program. If the event doesn't fire correctly, then what purpose is it good
for anyway?

I'm disappointed... I can't believe there is something more important than
fixing known bugs... :(
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top