如何使用ASP.NET C#获取数据集中的特定列数? [英] How to get particular column count in dataset using ASP.NET C#?

查看:79
本文介绍了如何使用ASP.NET C#获取数据集中的特定列数?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

从数据集中获取特定列数(从列开始到结束列)



我尝试过:



我尝试了很多方法但没有得到解决方案

get the particular column count from data set(Starting column to Ending column)

What I have tried:

I have tried many ways but not get the solution

推荐答案

DataSet 将不包含列

数据集将具有N个 DataTables ,这取决于上下文和用法。

DataTable 将仅包含

DataSet will not contain Columns
Dataset will be be having N number of DataTables, that depends on the context and usage.
DataTable will contain only Rows and Columns.
int count = dataTableName.Columns.Count; // to get the column count of a table 


这篇关于如何使用ASP.NET C#获取数据集中的特定列数?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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