Announcement

Collapse
No announcement yet.

Login Script help - Copying files

Collapse
X
  • Filter
  • Time
  • Show
Clear All
new posts

  • Login Script help - Copying files

    Hi all

    I am tring to copy 3 files (word template files) to each of the user's %appdata%\microsoft\templates folder on login.

    Using the COPY dos command, this is what I have tried and failed on:

    Code:
    copy \\server\share\normal.dot %appdata%\microsoft\templates
    Incorrect Syntax.

    Code:
    copy \\server\share\normal.dot C:\
    Incorrect Syntax

    Code:
    copy X:\folder\normal.dot C:\
    Works.

    This tells me it doesnt like UNC paths, so I map a drive letter...

    Code:
    copy X:\folder\normal.dot %appdata%microsoft\templates
    Incorrect Syntax, so it doesnt like %appdata% variable.

    Code:
    copy X:\folder\normal.dot "C:\Documents and Settings\All Users\Application Data\Microsoft\Templates"
    Works, but I need it in the user's appdata directory!

    Code:
    copy X:\folder\normal.dot "C:\Documents and Settings\%user%\Application Data\Microsoft\Templates"
    Doesnt work...

    Thats as far as I have got...any suggestions appreciated!

  • #2
    Re: Login Script help - Copying files

    Try Xcopy instead of copy.
    Marcel
    Technical Consultant
    Netherlands
    http://www.phetios.com
    http://blog.nessus.nl

    MCITP(EA, SA), MCSA/E 2003:Security, CCNA, SNAF, DCUCI, CCSA/E/E+ (R60), VCP4/5, NCDA, NCIE - SAN, NCIE - BR, EMCPE
    "No matter how secure, there is always the human factor."

    "Enjoy life today, tomorrow may never come."
    "If you're going through hell, keep going. ~Winston Churchill"

    Comment


    • #3
      Re: Login Script help - Copying files

      Thanks Dumber - saw this a little late but...

      I got it to work but adding in "'s like so:

      Code:
      copy \\server\share\normal.dot "%appdata\microsoft\templates\" /y
      What a palava! Now lets hope this solves the default font issue -.-;

      Comment


      • #4
        Re: Login Script help - Copying files

        ok glad you solved it
        Marcel
        Technical Consultant
        Netherlands
        http://www.phetios.com
        http://blog.nessus.nl

        MCITP(EA, SA), MCSA/E 2003:Security, CCNA, SNAF, DCUCI, CCSA/E/E+ (R60), VCP4/5, NCDA, NCIE - SAN, NCIE - BR, EMCPE
        "No matter how secure, there is always the human factor."

        "Enjoy life today, tomorrow may never come."
        "If you're going through hell, keep going. ~Winston Churchill"

        Comment

        Working...
        X