标签:style os sp strong 数据 on bs ad as
1. 获取数据库表头字段名称
DBGridEh2.Columns.Count //有多少个表头. 计数从0开始.
DBGridEh2.Columns[i].Field.FieldName; //获取表头字段名称, i 为某列
2. 获取某字段的所有行内容
DBGridEh2.DataSource.DataSet.First ;
repeat
Result.Add(DBGridEh2.DataSource.DataSet.FieldByName(‘CourseName‘).Value );
until (DBGridEh2.DataSource.DataSet.FindNext =False);
-----------
对应SQL语句: Select CourseName from 表名
标签:style os sp strong 数据 on bs ad as
原文地址:http://www.cnblogs.com/smartlittleant/p/4104562.html