none
VBS Scripting Error RRS feed

  • Question

  • Good afternoon,

    I've been playing around with this script and cannot get it to run without "network path not found". I see the line that the message refers to, but I'm not seeing how it's an error given the variables set up top.

    Can someone shed a little light on this for me please?

    --------------------------------------------------------------------------------------

    Option Explicit
    Dim objNetwork, strRemotePath1, strRemotePath2, strRemotePath3
    Dim strDriveLetter1, strDriveLetter2, strDriveLetter3

    strDriveLetter1 = "X:" 
    strDriveLetter2 = "Y:"
    strDriveLetter3 = "Z:" 
    strRemotePath1 = "\\largeformat1\working folder" 
    strRemotePath2 = "\\largeformat2\working folder"
    strRemotePath3 = "\\largeformat3\working folder" 

    Set objNetwork = CreateObject("WScript.Network") 

    objNetwork.MapNetworkDrive strDriveLetter1, strRemotePath1
    objNetwork.MapNetworkDrive strDriveLetter2, strRemotePath2
    objNetwork.MapNetworkDrive strDriveLetter3, strRemotePath3

    Wscript.Quit


    Friday, April 18, 2014 10:36 PM

Answers

  • Clearly the network path does not exist.  Have you tried to map a path at a prompt to verify that it exists?

    NET USE X: "\\largeformat1\working folder"

    I suspect you will get the same response.


    ¯\_(ツ)_/¯

    • Marked as answer by nicomen Friday, April 18, 2014 11:08 PM
    Friday, April 18, 2014 11:00 PM

All replies

  • Clearly the network path does not exist.  Have you tried to map a path at a prompt to verify that it exists?

    NET USE X: "\\largeformat1\working folder"

    I suspect you will get the same response.


    ¯\_(ツ)_/¯

    • Marked as answer by nicomen Friday, April 18, 2014 11:08 PM
    Friday, April 18, 2014 11:00 PM
  • Thank you jrv. Yes, I did. Strange. Maybe a hiccup in the network. Thank you for responding.
    Friday, April 18, 2014 11:11 PM