G
gouhaitao
Unregistered / Unconfirmed
GUEST, unregistred user!
procedure TForm2.btn1Click(Sender: TObject);
begin
con1.connected:=false;
con1.connectionstring:='Provider=SQLOLEDB.1;Password=1981121;Persist Security Info=True;User ID=cwal;Initial Catalog=service;Data Source='+trim(edt1.text);
try
con1.connected:=true; //连接远程服务器
except
messagebox(handle,'拥有半月别无所求!!','无敌风火轮',MB_OK+MB_ICONINFORMATION);
end;
为什么输错IP没有提示呀?还有这个加到哪最合适?IP是动态输入的!或者怎样处理这个比较好,请多给点建议
begin
con1.connected:=false;
con1.connectionstring:='Provider=SQLOLEDB.1;Password=1981121;Persist Security Info=True;User ID=cwal;Initial Catalog=service;Data Source='+trim(edt1.text);
try
con1.connected:=true; //连接远程服务器
except
messagebox(handle,'拥有半月别无所求!!','无敌风火轮',MB_OK+MB_ICONINFORMATION);
end;
为什么输错IP没有提示呀?还有这个加到哪最合适?IP是动态输入的!或者怎样处理这个比较好,请多给点建议