You can determine the number of active (visible) Forms like this:
private int CountActiveForms()
{
int cnt = 0;
foreach (Form theForm in Application.OpenForms) if (theForm.Visible) cnt++;
return cnt;
}
Try this simple test:
private void button1_Click(object sender, EventArgs e)
{
Form f1 = new Form();
f1.Show();
Form f2 = new Form();
f2.Show();
Form f3 = new Form();
f3.Show();
Form f4 = new Form();
f4.Show();
Console.WriteLine("Forms: Open: " + Application.OpenForms.Count.ToString() + " Active: " + CountActiveForms().ToString());
f1.Hide();
f4.Hide();
Console.WriteLine("Forms: Open: " + Application.OpenForms.Count.ToString() + " Active: " + CountActiveForms().ToString());
}