Here are the test results. I ran several versions of this using a trailing backslash and such.. The successful results are below.
FINDINGS:
(1)KiX 4.20 did not create the folders, but rather created files.
(2)NTDOC was correct, you do need to include trailing backslashes at various points of the script.
(3)KiXtart 4.21 - RC2 Documentation needs to be updated with this information especially the MOVE command.
Here is MCA's modified code with results included in.
code:
CLS
BREAK ON
?
? @kix
?
COPY "c:\kix1" "c:\kix2a\" /h ? "wait @error (@serror)"
;Creates a file with 4.20
;ADD A TRAILING BACKSLASH, GET A WAIT 3, PATH NOT SPECIFIED
;if c:\kix1 does not exist, no error reported under 4.20
;Creates a FOLDER with 4.21 RC-2 and no sub-folders
get $
COPY "c:\kix1" "c:\kix2b\" /h /s ? "wait @error (@serror)"
;creates a file with 4.20
;ADD A TRAILING BACKSLASH, GET A WAIT 3, PATH NOT SPECIFIED
;if c:\kix1 does not exist, no error reported under 4.20
;Creates a FOLDER with 4.21 RC-2 with sub-folders
get $
COPY "c:\kix1" "c:\kix3\" /s ? "wait @error (@serror)"
;creates a file with 4.20
;if c:\kix1 does not exist, no error reported under 4.20
;4.21 Results:
;(1)COPY "c:\kix1" "c:\kix3" /h /s ? "wait @error (@serror)"
;(1)parameter is incorrect error 87
;(2) COPY "c:\kix1" "c:\kix3\" /s ? "wait @error (@serror)"
;Operation completed successfully
get $
;Original command MOVE "c:\kix1" "c:\kix4" ? "wait @error (@serror)"
MOVE "C:\Kix1\" "C:\kix4\" ? "wait @error (@serror)"
;renames or moves kix1 to kix4 with 4.20 all files are intact
;if c:\kix1 does not exist, no error reported under 4.20
;4.21 results
;(1)MOVE "c:\kix1" "c:\kix4" /s ? "wait @error (@serror)"
;(1)parameter is incorrect error 87
;(2)MOVE "c:\kix1" "c:\kix4\" /s ? "wait @error (@serror)"
;(2)parameter is incorrect error 87
;(3)Documentation suggests
;(3)MOVE "C:Kix1" C:"kix4" ? "wait @error (@serror)"
;(3)kix4
;(3)wait 2 (The system cannot find the file specified.)
GET $
DEL "c:\kix3\" ? "wait @error (@serror)"
;Does not remove file or folder under 4.20
;4.21 results
;(1)path not specified
;(2)DELETES ALL FILES FROM C:\KIX3 and not the sub-folder
get $
DEL "c:\kix4\" /s ? "wait @error (@serror)"
;Removes files from C:\kix4 and not the subdirectory under 4.20
;4.21 results
;(1)path not specified
;(2) cannot find folder
get $
?
? "completed @kix"
Thanks,
Kent