J
Jacek Jurkowski
Why in thet case "throw" doesn't work?
There is no exception rising and there should
be!
public class Aaa
{
public static void Main()
{
try
{
Bbb bbb = new Bbb();
bbb.ShowDialog();
}
catch(Exception e)
{
MessageBox.Show(e.Message);
}
}
}
public class Bbb : Form
{
protected override OnLoad(EventArgs e)
{
base.OnLoad(e);
throw new Exception("exception");
}
}
There is no exception rising and there should
be!
public class Aaa
{
public static void Main()
{
try
{
Bbb bbb = new Bbb();
bbb.ShowDialog();
}
catch(Exception e)
{
MessageBox.Show(e.Message);
}
}
}
public class Bbb : Form
{
protected override OnLoad(EventArgs e)
{
base.OnLoad(e);
throw new Exception("exception");
}
}