-- 作者:cd_tdh
-- 发布时间:2019/9/30 11:28:00
--
老师,用代码都不行呢?生成的lvw控件,有上、下、左、右拉伸,麻烦看看。
Dim lvw0 As WinForm.ListView lvw0 = e.Form.CreateControl("ListView1",ControlTypeEnum.ListView) lvw0.SetBounds(0,0,704,368) \'lvw0.Dock= System.Windows.Forms.DockStyle.top \'停靠 lvw0.Anchor = system.Windows.Forms.AnchorStyles.Top Or system.Windows.Forms.AnchorStyles.Bottom Or system.Windows.Forms.AnchorStyles.Left Or system.Windows.Forms.AnchorStyles.Right \'锚定 e.Form.Controls("TabControl1").Tabpages(0).AddControl(lvw0)
Dim rad1 As WinForm.RadioButton rad1 = e.Form.CreateControl("RadioButton1",ControlTypeEnum.RadioButton) rad1.Text = "大图标" rad1.SetBounds(7,376,80,25) rad1.Dock= System.Windows.Forms.DockStyle.bottom \'停靠 rad1.Anchor = system.Windows.Forms.AnchorStyles.Left Or system.Windows.Forms.AnchorStyles.Bottom \'锚定 e.Form.Controls("TabControl1").Tabpages(0).AddControl(rad1)
Dim rad2 As WinForm.RadioButton rad2 = e.Form.CreateControl("RadioButton2",ControlTypeEnum.RadioButton) rad2.Text = "小图标" rad2.SetBounds(87,376,80,25) rad2.Dock= System.Windows.Forms.DockStyle.bottom \'停靠 rad2.Anchor = system.Windows.Forms.AnchorStyles.Left Or system.Windows.Forms.AnchorStyles.Bottom \'锚定 e.Form.Controls("TabControl1").Tabpages(0).AddControl(rad2)
Dim rad3 As WinForm.RadioButton rad3 = e.Form.CreateControl("RadioButton3",ControlTypeEnum.RadioButton) rad3.Text = "平铺" rad3.SetBounds(167,376,80,25) rad3.Dock= System.Windows.Forms.DockStyle.bottom \'停靠 rad3.Anchor = system.Windows.Forms.AnchorStyles.Left Or system.Windows.Forms.AnchorStyles.Bottom \'锚定 e.Form.Controls("TabControl1").Tabpages(0).AddControl(rad3)
Dim rad4 As WinForm.RadioButton rad4 = e.Form.CreateControl("RadioButton4",ControlTypeEnum.RadioButton) rad4.Text = "列表" rad4.SetBounds(247,376,80,25) rad4.Dock= System.Windows.Forms.DockStyle.bottom \'停靠 rad4.Anchor = system.Windows.Forms.AnchorStyles.Left Or system.Windows.Forms.AnchorStyles.Bottom \'锚定 e.Form.Controls("TabControl1").Tabpages(0).AddControl(rad4)
[此贴子已经被作者于2019/9/30 11:29:26编辑过]
|