J
Joep
Can you show us the ListChanged handler? StackOverflow => some (unintended,
unanticipated) loop that adds something with each iteration?
unanticipated) loop that adds something with each iteration?
Daniel O'Connell said:Could you perhaps provide the stack trace and, if possible, a short but
complete program[1] that exhibits your issue?
Its possible that there is something else in your application that is
causing the issue. Whittle down your code until it is nothing but the code
required to cause the problem. Although, contrary to the article, in this
case you would provide a GUI.
1. http://yoda.arachsys.com/csharp/complete.html (Its by Jon Skeet, another
C# MVP. I mention it only because the page itself is written in first person
and doesn't seem to mention who the author is.)
Jon Skeet said:Daniel O'Connell said:Could you perhaps provide the stack trace and, if possible, a short but
complete program[1] that exhibits your issue?
Its possible that there is something else in your application that is
causing the issue. Whittle down your code until it is nothing but the
code
required to cause the problem. Although, contrary to the article, in this
case you would provide a GUI.
Not quite contrary to the article - it only says to remove GUI aspects
if they're unnecessary. A question *about* a GUI is fine to include a
GUI, of course - although it should be as pared down as possible.
That's a good point. Would you like me to rewrite it in the third
person, or perhaps put a "who wrote this" bit at the start?
Daniel O'Connell said:Ya ya, I know. Don't need to be semantically precise do we?
My reading of the article suggests avoiding a GUI where possible and I just
wanted to make it clear that it is entirely appropriate here(although *it*
might have been possible to prove the bug without a GUI, atleast until I saw
the stack trace. I think its unlikely at this point). Although I could have
pointed it out in a different way.
Sorry for implying an error in your article, however,![]()
Being in the first person is fine, but I think atleast some accreditation is
in order. Something as simple as a "By Jon Skeet" would suffice nicely.
I don't want to appear to be claiming your work, afterall,.
One other point, however. You might want to suggest, for GUI related
questions, that the author take the extra step and avoid using the forms
designer(or any designer, for that matter, except where the designer is in
question). Right now its not too big of a deal, however, with the coming of
partial classes the forms designer is going to be one PITA to copy and paste
in. I worry we'll start to see
public partial class MyClass
{
//...
}
public partial class MyClass
{
private void InitalizeComponent()
{
//...
}
}
or simply two attached files.
Righto. Have a look in a few minutes and let me know if the change is
okay.