我有以下 C# 代码,为 .NET 3.5 编写,我想使用 1.1 版框架在 VB.NET 中编写此代码。
我可以将 C# 转换为 VB.NET,但我无法将 .NET 3.5 转换为 .NET 1.1,因为在 .net 1.1 中我们没有这些属性:RowCount
, CurrentRow
,Cells[index].value)
有人可以帮我转换这段代码吗?
if (DataGridView1.RowCount > 0)
{
TextBox1.Text = DataGridView1.CurrentRow.Cells[0].Value.ToString();
}
我要求不要建议我不要使用 .NET 1.1。
编辑:因为我正在使用 .NET 1.1(使用 VB.NET),所以我有一个 GridView 控件。如何访问它的单元格,就像我上面显示的 C# 代码