Re: NetUseAdd mystery

2007-02-27 Thread king kikapu
> You need to use level 2 info to pass the username. > Level 1 is for the old-style share with its own password. > Also, it should be 'username': instead of just 'user':. > > hth >Roger Roger many-many thanks! That was it, i had to put "username" instead of "user" and 2 instead of

Re: NetUseAdd mystery

2007-02-26 Thread Roger Upole
king kikapu wrote: > Is anyone see any error in the following code: > >mapDrive = "MyServer\\C$" >data = {'remote' : mapDrive, 'local' : 'M:', 'password' : > 'mypassword', 'user' : 'Administrator', 'asg_type' : 0} >win32net.NetUseAdd(None, 1, data) > > It gives me "pywi

Re: NetUseAdd mystery

2007-02-26 Thread king kikapu
> I think your problem is that C$ is a "special" share. Try creating > a share and connect to it instead. It is either that your your userid/ > password are in fact incorrect. > > -Larry No, my credentials are absolutely correct. As for the "$", what is the possible problem with that ?? Net use

Re: NetUseAdd mystery

2007-02-26 Thread Larry Bates
king kikapu wrote: > Is anyone see any error in the following code: > > mapDrive = "MyServer\\C$" > data = {'remote' : mapDrive, 'local' : 'M:', 'password' : > 'mypassword', 'user' : 'Administrator', 'asg_type' : 0} > win32net.NetUseAdd(None, 1, data) > > It gives me "

NetUseAdd mystery

2007-02-26 Thread king kikapu
Is anyone see any error in the following code: mapDrive = "MyServer\\C$" data = {'remote' : mapDrive, 'local' : 'M:', 'password' : 'mypassword', 'user' : 'Administrator', 'asg_type' : 0} win32net.NetUseAdd(None, 1, data) It gives me "pywintypes.error: (1326, 'NetUseAd