586 Star 4.6K Fork 1.2K

冰封一夏 / HZHControls控件库

 / 详情

垂直菜单导行报错

待办的
创建于  
2021-09-17 21:16

在 HZH_Controls.Controls.UCMenu.parentItem_SelectedItem(Object sender, EventArgs e)
在 HZH_Controls.Controls.UCMenu.ReloadItems()
在 HZH_Controls.Controls.UCMenu.set_DataSource(List`1 value)
在 KuaiHuiProgram.MainForm.Init() 位置 D:\work\KuaiHuiProgram\KuaiHuiProgram\MainForm.cs:行号 47
在 KuaiHuiProgram.MainForm.MainForm_Load(Object sender, EventArgs e) 位置 D:\work\KuaiHuiProgram\KuaiHuiProgram\MainForm.cs:行号 60
在 System.Windows.Forms.Form.OnLoad(EventArgs e)
在 System.Windows.Forms.Form.OnCreateControl()
在 System.Windows.Forms.Control.CreateControl(Boolean fIgnoreVisible)
在 System.Windows.Forms.Control.CreateControl()
在 System.Windows.Forms.Control.WmShowWindow(Message& m)
在 System.Windows.Forms.Control.WndProc(Message& m)
在 System.Windows.Forms.ScrollableControl.WndProc(Message& m)
在 System.Windows.Forms.Form.WmShowWindow(Message& m)
在 System.Windows.Forms.Form.WndProc(Message& m)
在 System.Windows.Forms.Control.ControlNativeWindow.OnMessage(Message& m)
在 System.Windows.Forms.Control.ControlNativeWindow.WndProc(Message& m)
在 System.Windows.Forms.NativeWindow.DebuggableCallback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)

List lstMenu = new List();
for (int i = 0; i < 5; i++)
{
MenuItemEntity item = new MenuItemEntity()
{
Key = "p" + i.ToString(),
Text = "菜单项" + i,
//DataSource = ""
};
item.Childrens = new List();
for (int j = 0; j < 5; j++)
{
MenuItemEntity item2 = new MenuItemEntity()
{
Key = "c" + i.ToString(),
Text = "菜单子项" + i + "-" + j,
DataSource = ""
};
item.Childrens.Add(item2);
}
lstMenu.Add(item);
}
this.ucMenu1.DataSource = lstMenu;

评论 (0)

高腾龙 创建了任务
展开全部操作日志

登录 后才可以发表评论

状态
负责人
里程碑
Pull Requests
关联的 Pull Requests 被合并后可能会关闭此 issue
分支
开始日期   -   截止日期
-
置顶选项
优先级
参与者(1)
C#
1
https://gitee.com/kwwwvagaa/net_winform_custom_control.git
git@gitee.com:kwwwvagaa/net_winform_custom_control.git
kwwwvagaa
net_winform_custom_control
HZHControls控件库

搜索帮助