We can't answer this for you - you need to work it out for yourself. Why? Because we can't run your code, and this is a run time problem which can't be "worked out" just from looking at trivial code fragments in isolation.
Let me explain why it's happened: something in your code is probably causing recursion. I.e. some action in your code causes the same action to happen again. For example, imagine you have a form, and you handle it's "resize" event. If in the resize event handler you change the size of the form, the resize event will happen again. And again. And again ... until something catastrophic happens and the system collapses. A simpler way to do this is to call a method from inside the method either directly:
void xx()
{
xx();
}
Or indirectly:
void xx()
{
yy();
}
void yy()
{
xx();
}
At some point you run out of space on the stack to store the return addresses and you get a "stack overflow" exception.
That's what's happened here - something has run out of stack space, and direct or indirect recursion is the most likely cause.
So use the debugger, look at the exception detail, look at the stack trace. see if you can see where it all started, and put a breakpoint on that line and run your code again. Now look closely at all the variables, and step your code line-by-line. Look for something happening that you didn't expect.
Sorry, but we can't do any of that for you!