如何在datagridview的特定单元格中显示文本 [英] how can i display a text in a specific cell of a datagridview
本文介绍了如何在datagridview的特定单元格中显示文本的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
大家好,我的问题是我正在开发一个带有datagridview的屏幕,在一行中我输入一条记录的代码(id),然后显示一个名称(该文件中代码的描述)同一行上的特定单元格和该单元格将同时激活,简而言之,如何在datagridview的特定单元格中显示文本
解决方案<对于特定单元格的/ div>
试试这个
dataGridView1.Rows [ 3 ]。 [ 1 ]。值= YourText
Hello to all, my problem is that i am developing a screen with a datagridview where on a row i type the code(id) of a record and then the name(description of that code in the file) is display in a specific cell on the same row and that cell will be activated at the same time, in short how can i display a text in a specific cell of a datagridview
解决方案
for a specific cell try this
dataGridView1.Rows[3].Cells[1].Value = "YourText";
这篇关于如何在datagridview的特定单元格中显示文本的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文