for i := 0 to GroupBox1.ComponentCount -1 do if (GroupBox1.Components[i]) is TWinControl then TWinControl(GroupBox1.Components[i]).Enabled:=False;
但ComponentCount总是返回0,我错过了什么?