I get a stackoverflow exception on following commented lines.
namespace Football_Manager_WFA
{
public partial class Settings : Form
{
Color def_bgdColor = SystemColors.Control;
Color def_fontColor = Color.Black; // ERROR
static FontFamily fontFamily = FontFamily.GenericSansSerif;
Font def_fontType = new Font(fontFamily, 8.0f); // ERROR
}
}
Surprisingly, the problem wasn’t in the line with the error.
I initialized Settings form on two places, two times.
So just deleted one of them and it works now. Thanks to Henk for a hint.