for i := 0 to Application.ComponentCount - 1 do if Application.Components[i] is TForm then Showmessage(TForm(Application.Components[i]).Name);
sl: TStringList;...sl.Clear;for i := 0 to Components.Count - 1 do sl.Values(Components[i].ClassName) := IntToStr(StrToIntDef(sl.Values(Components[i].ClassName), 0) + 1));