If anyone is using the AutoRunUSB program, I got a couple batch files that are working well.
I have 2 different files, one is
autorun.bat (launched when the drives is in my home PC) and
autoruncar.bat (launched when in the car). I did this because my computers were having a hard time with the goto Carpc command and it was an easy fix to make 2 files.
I added a delete command in the
autoruncar.bat so that after files had transferred it would then empty the media folders (just music and movies, not the RR files) so that next time I needed to transfer files the drive was "unloaded" and ready.
Here they are:
autorun.bat:
Code:
ECHO OFF
REM Road Runner
xcopy "C:\Program Files\Road Runner\*.*" "G:\car\Road Runner\*.*" /S /D /K /I /Y
if errorlevel 4 goto lowmemory
if errorlevel 2 goto abort
REM Music/Movies Transfer
xcopy "C:\My Music\To Transfer\*.*" "G:\*.*" /S /D /K /I /Y
if errorlevel 4 goto lowmemory
if errorlevel 2 goto abort
ECHO .
ECHO .
ECHO USB Drive is now ready to sync with CarPC!!!
ECHO .
goto Finish
REM -----------------------
REM WHEN THINGS GO WRONG!!!
:lowmemory
echo Insufficient memory to copy files or
echo invalid drive or command-line syntax.
goto exit
:abort
echo You pressed CTRL+C to end the copy operation.
REM -----------------------
:Finish
ECHO Finished!!!
ECHO .
ECHO .
PAUSE
exit
autoruncar.bat:
Code:
ECHO OFF
REM RoadRunner Folder
xcopy "D:\car\Road Runner\*.*" "C:\Program Files\Road Runner\*.*" /S /D /K /I /Y
if errorlevel 4 goto lowmemory
if errorlevel 2 goto abort
REM Music Folder (Hide display while copying)
xcopy "D:\music\*.*" "C:\Music\*.*" /S /D /K /I /Y
if errorlevel 4 goto lowmemory
if errorlevel 2 goto abort
REM Movies Folder (Hide display while copying)
xcopy "D:\movies\*.*" "C:\movies\*.*" /S /D /K /I /Y
if errorlevel 4 goto lowmemory
if errorlevel 2 goto abort
REM Delete Transferred Media
del D:\movies\*.* /Q /S
del D:\music\*.* /Q /S
ECHO .
ECHO .
ECHO CarPC is up-to-date!!!
ECHO .
"C:\Program Files\Road Runner\RR.exe"
goto Finish
REM -----------------------
REM WHEN THINGS GO WRONG!!!
:lowmemory
echo Insufficient memory to copy files or
echo invalid drive or command-line syntax.
goto exit
:abort
echo You pressed CTRL+C to end the copy operation.
REM -----------------------
:Finish
ECHO Finished!!!
ECHO .
ECHO .
exit
MY PROBLEM:
The original bat file that Ruari made had TASKKILL commands that would exit the apps being updated (in my case I only need RR closed when I use the carPC). He has XP Pro and I have Home. My XP does not recognize TASKKILL as a command and is not able to close the apps.
Does anyone know of other commands to use instead that XP Home edition will recognize? Or a list of commands that I can go through and find one that works?
Thanks.
ed.