J
jarry888
Unregistered / Unconfirmed
GUEST, unregistred user!
程序是在我这台机器编写的!
ADOConnection我的连接是这样的?
该如何解决?
procedure Tmain_Form.FormCreate(Sender: TObject);
var str:string;
//ConnectStr:WideString;
begin
ADOConnection1.Connected:=false;
ADOConnection1.ConnectionString:='';
str:=GetUserName;//系统登录用户{GetUserName是个涵数返回值}
ADOConnection1.ConnectionString:='Provider=SQLOLEDB.1;Persist Security Info=False;Initial Catalog=report;Data Source=server_2;Use Procedure for Prepare=1;Auto Translate=True;Packet Size=4096;Workstation ID='+str;
ADOConnection1.Connected:=true;
ADOConnection1.KeepConnection:=true;
end;
ADOConnection我的连接是这样的?
该如何解决?
procedure Tmain_Form.FormCreate(Sender: TObject);
var str:string;
//ConnectStr:WideString;
begin
ADOConnection1.Connected:=false;
ADOConnection1.ConnectionString:='';
str:=GetUserName;//系统登录用户{GetUserName是个涵数返回值}
ADOConnection1.ConnectionString:='Provider=SQLOLEDB.1;Persist Security Info=False;Initial Catalog=report;Data Source=server_2;Use Procedure for Prepare=1;Auto Translate=True;Packet Size=4096;Workstation ID='+str;
ADOConnection1.Connected:=true;
ADOConnection1.KeepConnection:=true;
end;