Hi all, I'm new to Perl and I'm trying to use it to connect to a shared disc through a home network. This is what I've tried: -------------------------------------------------------------------------------------------------------------------- #!/usr/bin/perl -w use Win32::NetResource; $RemoteShare = { 'LocalName' => "X:", 'RemoteName' => "\\\\Nash", }; $UserName = "No Name"; $Password = ""; $Connection = 1; Win32::NetResource::AddConnection($RemoteShare,$Password,$UserName, $Connection) or print "unable to add Nash\n";
Win32::NetResource::GetError( $ErrorCode ); print "Error code is $ErrorCode"; ----------------------------------------------------------------------------------------------------------------------- The program actually works if I omit the 'LocalName' definition in line 4, i.e. it makes the connection. However, since I don't have a local name I can't subseqently cancel the connection, and I'd like to be able to do that. With the local name definition, the program doesn't make the connection, reporting an error code of 1200. So: 1. What am I doing wrong? 2. Where can I find the error codes and their meanings? TIA, Nash -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] http://learn.perl.org/