D
dwqxj
Unregistered / Unconfirmed
GUEST, unregistred user!
这是我的程序,不能通过,
netsource : tnetresource;
with netsourcedo
//登录
begin
dwtype := resourcetype_any;
lplocalname:='x:';
lpremotename:=pchar(downpath);
//为服务器路径: //192.168.28.2/aaa/
lpprovider:='';
end;
if wnetaddconnection2(netsource,pchar(s_pwd),pchar(s_user),0)=NO_ERROR then
memo1.lines.Add('服务器登录成功!')
else
begin
memo1.lines.Add('服务器登录失败!');
exit;
end;
netsource : tnetresource;
with netsourcedo
//登录
begin
dwtype := resourcetype_any;
lplocalname:='x:';
lpremotename:=pchar(downpath);
//为服务器路径: //192.168.28.2/aaa/
lpprovider:='';
end;
if wnetaddconnection2(netsource,pchar(s_pwd),pchar(s_user),0)=NO_ERROR then
memo1.lines.Add('服务器登录成功!')
else
begin
memo1.lines.Add('服务器登录失败!');
exit;
end;