System.StackOverflowException was unhandled - C#, .NET
13,238
Solution 1
Your function is calling itself forever.
You need to make it stop calling itself.
In this case, you need to Invoke
it to the UI thread instead of simply calling itself again:
Invoke(new Action(UpdateAdvert));
Solution 2
It appears that InvokeRequired
is true
. This causes unbounded recursion. There's nothing that will change it to false. Perhaps invoking would fix it?
Author by
Hooch
Updated on June 19, 2022Comments
-
Hooch almost 2 years
How to fix it. It look like this page is dedicated to that kind of error.