Page 1 of 1

Filecopy sets errorlevel when copying tro a NAS

Posted: 30 Mar 2020, 08:23
by peter9999
Wrote script for managing my Backups to a NAS, but copying to a NAS with FileCopy doesn´t work and sets ErrorLevel to "1". I extracted the relevant code to

Code: Select all

Ziel2:="Q:\Sicherung"
Name:="Daten"
Ziel:="D:\Sicherung\Daten"
FileCopy, %Ziel%\Full_%Name%_TMP.sna, %Ziel2%\Full_%Name%_%A_YYYY%%A_MM%%A_DD%%A_Hour%%A_Min%.sna
ListVars
Pause
Q: is the NAS. Copying the same file to another location works fine, copying to the NAS from command window works also.

thx in advance!
peter

Re: Filecopy sets errorlevel when copying tro a NAS

Posted: 30 Mar 2020, 10:32
by flyingDman
Using filecopy on my Synology NAS works fine. Have you tried using the \\server\... address? This works here as well:

Code: Select all

filecopy, C:\Users\xxx\docs\test.txt ,\\myserver\xxxx\docs, 1

Re: Filecopy sets errorlevel when copying tro a NAS

Posted: 01 Apr 2020, 11:35
by peter9999
thx for the tip, it works now. :thumbup:
But: WHY does the former way NOT work??? :roll:

peter

Re: Filecopy sets errorlevel when copying tro a NAS

Posted: 01 Apr 2020, 15:30
by flyingDman
I do not know. I have had instances where I could not use the assigned drive letter and had to use the network address. That's the first that came to mind when I saw your post.