#22328 - 2002-05-29 05:33 PM
ECHO A|
|
Austin
Seasoned Scripter
Registered: 2002-01-24
Posts: 439
|
I am trying to do the following..
code:
Shell 'ECHO A| XCOPY /E $SRC $COMP$DSTDRV\eEntrprs'
It works fine without the ECHO A| in there.. I am just trying to answer the overwrite request. I know this is how you do it in bat file... can anyone offer advice?
Thanks
_________________________
Austin Henderson
|
|
Top
|
|
|
|
#22330 - 2002-05-29 05:49 PM
Re: ECHO A|
|
Howard Bullock
KiX Supporter
   
Registered: 2000-09-15
Posts: 5809
Loc: Harrisburg, PA USA
|
Have you considered: /Y Suppresses prompting to confirm you want to overwrite an existing destination file.
or
The switch /Y may be preset in the COPYCMD environment variable.
Also if you want to use the ECHO then try :
Shell '%comspec% /c echo A| ...'
|
|
Top
|
|
|
|
#22331 - 2002-05-29 05:49 PM
Re: ECHO A|
|
MCA
KiX Supporter
   
Registered: 2000-04-28
Posts: 5152
Loc: Netherlands, EU
|
Dear,
XCOPY use another way of overwriting existing files. Important switches are - /Y Overwrites existing files without prompting. - /C Continues copying even if errors occur. Our suggestion is:
code:
SHELL '%compsec /c XCOPY "$src" "$comp$dstdrv\eEntrprs" /E /Y /C /I /R'
Possible parameters:
code:
Copies files and directory trees.
XCOPY source [destination] [/A | /M] [/D[:date]] [/P] [/S [/E]] [/W] [/C] [/I] [/Q] [/F] [/L] [/H] [/R] [/T] [/U] [/K] [/N]
source Specifies the file(s) to copy. destination Specifies the location and/or name of new files. /A Copies files with the archive attribute set, doesn't change the attribute. /M Copies files with the archive attribute set, turns off the archive attribute. /D:date Copies files changed on or after the specified date. If no date is given, copies only those files whose source time is newer than the destination time. /P Prompts you before creating each destination file. /S Copies directories and subdirectories except empty ones. /E Copies directories and subdirectories, including empty ones. Same as /S /E. May be used to modify /T. /W Prompts you to press a key before copying. /C Continues copying even if errors occur. /I If destination does not exist and copying more than one file, assumes that destination must be a directory. /Q Does not display file names while copying. /F Displays full source and destination file names while copying. /L Displays files that would be copied. /H Copies hidden and system files also. /R Overwrites read-only files. /T Creates directory structure, but does not copy files. Does not include empty directories or subdirectories. /T /E includes empty directories and subdirectories. /U Updates the files that already exist in destination. /K Copies attributes. Normal Xcopy will reset read-only attributes. /Y Overwrites existing files without prompting. /-Y Prompts you before overwriting existing files. /N Copy using the generated short names.
greetings.
|
|
Top
|
|
|
|
#22332 - 2002-05-29 05:50 PM
Re: ECHO A|
|
Howard Bullock
KiX Supporter
   
Registered: 2000-09-15
Posts: 5809
Loc: Harrisburg, PA USA
|
Darn it Shawn... I just get some time while on furlough and everyone still beats me to the punch. I just can't seem to be fast enough. [ 29 May 2002, 17:51: Message edited by: Howard Bullock ]
|
|
Top
|
|
|
|
#22333 - 2002-05-29 05:51 PM
Re: ECHO A|
|
Shawn
Administrator
   
Registered: 1999-08-13
Posts: 8611
|
whoa ! a three car pile-up, thats a record, me thinks
Howard, your answer was better than mine anyways !
-Shawn
p.s. Checkout the timestamp on all three of our replies ! heheh [ 29 May 2002, 17:53: Message edited by: Shawn ]
|
|
Top
|
|
|
|
#22334 - 2002-05-29 05:58 PM
Re: ECHO A|
|
MCA
KiX Supporter
   
Registered: 2000-04-28
Posts: 5152
Loc: Netherlands, EU
|
Shawn,
I agree with you. It is already fast that two members enter a reaction a the same time. The chance for three entries at same time wasn't something we could imagine.
More important is: you don't need to wait long for a solution. It shows that the KiXtart site isn't sleep at all. That is why KiXtart people loves this site. greetings.
|
|
Top
|
|
|
|
#22335 - 2002-05-29 06:06 PM
Re: ECHO A|
|
Howard Bullock
KiX Supporter
   
Registered: 2000-09-15
Posts: 5809
Loc: Harrisburg, PA USA
|
That's too strange. Maybe we should start playing a lottery...
|
|
Top
|
|
|
|
#22336 - 2002-05-29 06:11 PM
Re: ECHO A|
|
MCA
KiX Supporter
   
Registered: 2000-04-28
Posts: 5152
Loc: Netherlands, EU
|
Playing a lottery is only interesting, when nobody can have influence on the results. Which persons doesn't want to know - who wins the game. - which share get the biggest progress. - what happens tomorrow. greetings.
|
|
Top
|
|
|
|
#22337 - 2002-05-29 06:18 PM
Re: ECHO A|
|
Shawn
Administrator
   
Registered: 1999-08-13
Posts: 8611
|
Oh, it gets weirder Howard, much weirder ...
There were 3 posts, all at the same time.
We all have the number 3 in our member number.
MCA's member number (732) divided by my member number (173), rounded, equals 4.
Your member number (3386) divided by MCA's member number (732), rounded equals 4.
It's freakin me out !!!
-Shawn
ROFLMAO [ 29 May 2002, 18:23: Message edited by: Shawn ]
|
|
Top
|
|
|
|
#22338 - 2002-05-29 06:25 PM
Re: ECHO A|
|
Austin
Seasoned Scripter
Registered: 2002-01-24
Posts: 439
|
I am an idiot.. sorry to even post. I think I was stuck back in the NT 4.0 days.. I think I recall the /Y not being an option in the previous versions or something and that is why in the older scripts I just used the ECHO A|.. I know there was some valid reason..
; (
That just makes me mad.
Have good day guys.
_________________________
Austin Henderson
|
|
Top
|
|
|
|
#22341 - 2002-05-30 08:48 PM
Re: ECHO A|
|
Austin
Seasoned Scripter
Registered: 2002-01-24
Posts: 439
|
Ahh... so maybe I am not an idiot. I knew there was some reason we had to do that.
Thanks for your help. I suppose I was just remembering the older version.
_________________________
Austin Henderson
|
|
Top
|
|
|
|
Moderator: Jochen, Allen, Radimus, Glenn Barnas, ShaneEP, Ruud van Velsen, Arend_, Mart
|
0 registered
and 1046 anonymous users online.
|
|
|