Loading ...
Sorry, an error occurred while loading the content.

BATCH HELP

Expand Messages
  • alex
    Hello all- i need help with a batch file checking if any of you already have that batch in place. i am trying to write a bactch file to copy and paste file
    Message 1 of 2 , Sep 26, 2012
    • 0 Attachment
      Hello all-

      i need help with a batch file checking if any of you already have that batch in place. i am trying to write a bactch file to copy and paste file from a share network drive to users computers. that batch file will need to call a txt file that contains all the computers names to copy to.

      thanks

      alex
    • Aleksey D. Tetyorko
      Hi! ============================================================================== i am trying to write a bactch file to copy and paste file from a share
      Message 2 of 2 , Sep 29, 2012
      • 0 Attachment
        Hi!
        ==============================================================================
        i am trying to write a bactch file to copy and paste file from a share
        network drive to users computers. that batch file will need to call a txt
        file that contains all the computers names to copy to.
        ==============================================================================

        As I see it, it can be done as follows:

        Let file users.txt contains lines:

        \\computer1\share1\
        \\computer2\share2\
        .....
        \\computerN\c$\
        .....

        Your batch can use:

        for /F %%d in (users.txt) do xcopy yourfile %%d

        Try 'copy' instead of 'xcopy' and some combination of switches in 'for' and
        '[x]copy' command lines.

        Maybe your task needs switching args: copy %%d yourfile.

        Aleksey
      Your message has been successfully submitted and would be delivered to recipients shortly.