一个datagridview单元中的多个控件 [英] multiple controls in one datagridview cell

查看:242
本文介绍了一个datagridview单元中的多个控件的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

一个datagridview单元中有多个控件.我想在我的C#.net Windows应用程序的一个datagridview单元中添加两个控件,请不要绘制控件.可以的.请给我一个解决方案.请不要绘制控件..........

谢谢你……

关于
..............................................

multiple controls in one datagridview cell. I want Add two controls in one datagridview cell my C#.net windows application please don,t draw the controls . It is possible to do.Pls give me a solution.pls Don''t draw the controls.............

Thanking You......

Regarding
.....................................

推荐答案

Windows Forms控件可以托管在DataGridViewCell中.这里给出一个例子
如何:在Windows窗体DataGridView单元中托管控件 [
Windows Forms controls can be hosted in a DataGridViewCell. An example is given here
How to: Host Controls in Windows Forms DataGridView Cells[^] which shows how to create a calendar column.
The cells of this column display dates in ordinary text box cells, but when the user edits a cell, a DateTimePicker control appears. In order to avoid having to implement text box display functionality again, the CalendarCell class derives from the DataGridViewTextBoxCell class rather than inheriting the DataGridViewCell class directly. as explained at the above reference.

I think it may be helpful.


这篇关于一个datagridview单元中的多个控件的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
相关文章
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆