关于DataGridView组合框列C# [英] Regarding DataGridView Combobox Column C#

查看:103
本文介绍了关于DataGridView组合框列C#的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

你好,

我做了一个ownerdrawn的Combobox,也做了一个带有ComboboxColumn的DataGridView.

现在我要做的是用我的ownerDrawn Combobox替换DatagridView Combobox列.

我该如何实施?
谁能帮我吗?

提前谢谢您.

问候,
Lakshman

Hello,

I have made a ownerdrawn Combobox and also a DataGridView With a ComboboxColumn.

Now what I have to do is I Want to replace the DatagridView Combobox column With my ownerDrawn Combobox.

How Can I implement this?
Can anyone please help me?

Thank you in advance.

Regards,
Lakshman

推荐答案

说起来容易做起来难.由于您的控件必须服从DGV的命令并支持其各种模式,因此这是一项繁重的工作.例如,当不编辑其呈现的行时,您的自定义列会做什么?用户单击一行时该怎么办?现在,当用户开始编辑该行中的YOUR列时?

您可以找到示例
Easier said than done. It''s a bunch of work since your control has to obey the DGV''s commands and support its various modes. For example, what does your custom column do when the row it''s rendering is not being edited? What does it do when the user clicks a row? Now when the user starts editing YOUR column in that row?

You can find examples here[^].


这篇关于关于DataGridView组合框列C#的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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