读书人

ConnectionString有关问题

发布时间: 2012-02-25 10:01:47 作者: rapoo

求助,ConnectionString问题,急!!!
procedure Tloginfm.FormCreate(Sender: TObject);
var
mypath:string;
begin
j:=0;
mypath:=extractfilepath(paramstr(0));
ADOquery.ConnectionString:= 'Provider=Microsoft.Jet.OLEDB.4.0;Data Source= '+mypath+ 'data\kcgl.mdb;Persist Security Info=False ';
ADOquery.active:=true;【1】
with adoquery do
begin
close;
sql.Clear;
sql.Add( 'select * from czyb ');
open;
if recordcount> 0 then
begin
first;
while not eof do
begin
usernamebox.Items.Add(fieldbyname( '姓名 ').AsString);
next;
end;
end
为什么将 【1】 改成oracle的ConnectionString 无法正常连接呢 是什么原因造成的 该怎么修改?

[解决办法]
看程序报的什么错.详细错误信息.

读书人网 >.NET

热点推荐