无面板继承的类面板控件

编程入门 行业动态 更新时间:2024-10-21 20:29:51
本文介绍了无面板继承的类面板控件的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧! 问题描述

我想知道面板和tabcontrol控件如何允许用户将控件拖放到它们上,我想构建类似的东西,但是找不到任何有用的东西. 继承面板或tabcontrol类是我不想做的事情,我真的很想知道拖放与设计器如何工作. 另外,我想用C#做到这一点. 预先感谢, Nbgangsta

I was wondering about how the panel and tabcontrol controls allow the user to drag and drop controls onto them, I''m want to build something alike but can''t find anything of use. Inheriting the panel or tabcontrol class is something I don''t want to do, I really want to know how the drag and drop works with the designer. Also, I''d like to do this with C#. Thanks in advance, Nbgangsta

推荐答案

它们处理各种拖动事件: DragEnter DragLeave DragDrop DragOver ItemDrag GiveFeedback 您可以在所需的任何控件上处理这些事件.这是一个不错的链接: www.c-sharpcorner/uploadfile/mgold/doingdraganddropusingcsharp11302005020610am/doingdraganddropusingcsharp.aspx /a> [ ^ ] They handle the various drag events: DragEnter DragLeave DragDrop DragOver ItemDrag GiveFeedback You can handle those events on any control you want. Here''s a decent link: www.c-sharpcorner/uploadfile/mgold/doingdraganddropusingcsharp11302005020610am/doingdraganddropusingcsharp.aspx[^]

更多推荐

无面板继承的类面板控件

本文发布于:2023-11-06 13:44:59,感谢您对本站的认可!
本文链接:https://www.elefans.com/category/jswz/34/1563857.html
版权声明:本站内容均来自互联网,仅供演示用,请勿用于商业和其他非法用途。如果侵犯了您的权益请与我们联系,我们将在24小时内删除。
本文标签:面板   控件

发布评论

评论列表 (有 0 条评论)
草根站长

>www.elefans.com

编程频道|电子爱好者 - 技术资讯及电子产品介绍!