说明:
经本人用uledit研究
Access2000格式mdb文件从9c开始的三个字节为"4.0",97则无,用Delphi编写的函数如下:
function isaccess2000(filepath:string):boolean;
//判断文件是否为access2000格式,Mailto:shirong21cn@163.com" rel="nofollow">shirong21cn@163.com
const
veraddr=$9c;
var
strbuf:array[0..2]of byte;
f:tfilestream;
i:integer;
p:pchar;
begin
f:=TFileStream.Create(FilePath,fmShareDenyNone);
try
F.Seek(veraddr,soFromBeginning);
F.Read(strBuf,3);
p:=@strbuf;
if p='4.0' then result:=true
else result:=false;
finally
f.free;
end;
怎么没人反映意见?我删了它!
end;
来自 “ ITPUB博客 ” ,链接:http://blog.itpub.net/10752043/viewspace-992112/,如需转载,请注明出处,否则将追究法律责任。
转载于:http://blog.itpub.net/10752043/viewspace-992112/