以文本方式查看主题 - Foxtable(狐表) (http://www.foxtable.com/bbs/index.asp) -- 专家坐堂 (http://www.foxtable.com/bbs/list.asp?boardid=2) ---- [讨论] 动态增加的表能不能放到分区面板或分组框中 (http://www.foxtable.com/bbs/dispbbs.asp?boardid=2&id=3230) |
-- 作者:gamtings -- 发布时间:2009/6/22 8:58:00 -- [讨论] 动态增加的表能不能放到分区面板或分组框中 Dim t As WinForm.Table t = e.Form.CreateControl("表A", ControlTypeEnum.Table) t.SetBounds(10,10,400,300) e.Form.AddControl(t) 用以上代码动态增加的表能不能放到SplitContainer(分区面板)或GroupBox(分组框)中? 这样是不是会更灵活一点? |
-- 作者:狐狸爸爸 -- 发布时间:2009/6/22 9:11:00 -- GroupBox有AddControl方法的。 SplitContainer有Panel1属性,表示第一个分区面板,Panel1同样有AddControl方法,第二个分区面板用Panel2表示。 Dim sp As WinForm.SplitContainer = e.Form.Controls("SplitContainer1") Dim lbl As WinForm.Label lbl = e.Form.CreateControl("lable1", ControlTypeEnum.Label) lbl.Text = "Foxtable" lbl.Left = 100 lbl.Top = 100 sp.Panel1.AddControl(lbl) |
-- 作者:gamtings -- 发布时间:2009/6/22 9:30:00 -- 明白,谢谢!!! |