送分!怎样用VC++6.0获得ACCESS2000中的表和字段的名称(不使用DAO、RDO、ADO)?(100分)

J

joyzw

Unregistered / Unconfirmed
GUEST, unregistred user!
凡附完整的源代码并注有说明者绝对有分!
 
bde 吗?gettablename
With Table1do
begin
For i:=0 to FieldCount-1do
begin
S:='';
s:=S+Fields.Fieldname;
If length(S)<16 then
S:=S+Space(16-length(S));
case (Fields.dataType) of
ftString: S:=S+' CHAR('+IntToStr(Fields.dataSize-1)+')';
ftInteger: s:=S+' Integer';
ftSmallInt: s:=S+' Integer';
ftFloat: s:=S+' Float';
ftdate: s:=S+' DateTime';
else
s:=s+' ';
end;
S:=S+' NULL';
If i<FieldCount-1 then
S:=S+',';
List.Lines.Add(s);
end;
List.Lines.Add(')');
List.Visible:=False;
List.Visible:=True;
end;
不会vc
 
找个MDB文件的格式说明,直接读文件!
 
哈哈,那能不能用ODBC啊?
 
利用odbc中的编目函数可以实现。
 
你这位老兄不是坑人吗,现成的不用,还要追求别的什么办法,我只能说你去看看access
数据库的组织结构吧!
 
那微软的ACCESS不是白做了?
 

Similar threads

顶部