home bbs files messages ]

Forums before death by AOL, social media and spammers... "We can't have nice things"

   alt.msdos.batch      Fun with MS-DOS batch files      42,547 messages   

[   << oldest   |   < older   |   list   |   newer >   |   newest >>   ]

   Message 40,672 of 42,547   
   Todd Vargo to andrewniebling@gmail.com   
   Re: MOVE cmd and output redirection   
   30 May 13 15:03:25   
   
   From: tlvargo@sbcglobal.netz   
      
   On 5/30/2013 12:42 AM, andrewniebling@gmail.com wrote:   
   > Yes everything exists as it should and the only time i get a error message   
   in the log file using 2>&1 is if i run the batch twice then it will say "The   
   system cannot find the file specified." as i would expect as it has already   
   moved the files.   
   >   
   > I have found another way to do it i created another folder in the dir of   
   P:\ABRplans\Survey Plans\ called SP_Done and put my files to be copied in   
   there and then if i put this in my mapbasic code:   
   >   
   > Define REPORT_FILE "G:\zGIS_Data_Editing\QR_Log_Files\Survey_P   
   ans\SurveyPlanLink.Log"   
   >   
   > Dim MOVEsurveyplan as string   
   >   
   > MOVEsurveyplan = "cmd /c move /y ""P:\ABRplans\Survey Plans\SP_Done\*.pdf""   
   ""G:\QRData\SurveyPlans\Linked\""" &">>"& REPORT_FILE   
   >   
   > Run Program MOVEsurveyplan   
   >   
   > it puts the following in my log file   
   >   
   > P:\ABRplans\Survey Plans\SP_Done\LN1264.pdf   
   > P:\ABRplans\Survey Plans\SP_Done\RM76.pdf   
   > P:\ABRplans\Survey Plans\SP_Done\RP152112.pdf   
   > P:\ABRplans\Survey Plans\SP_Done\RP612595.pdf   
   > P:\ABRplans\Survey Plans\SP_Done\SP229947.pdf   
   > P:\ABRplans\Survey Plans\SP_Done\SP230852.pdf   
   > P:\ABRplans\Survey Plans\SP_Done\SP230914.pdf   
   > P:\ABRplans\Survey Plans\SP_Done\SP253700.pdf   
   >   
   >   
   > Not sure why this way works and the other does'nt. I would prefer to get the   
   original working if i could but if not i guess this will have to do....   
   >   
      
   I suspect it is the difference between using Winexec and Run. You will   
   have to read the docs because I am not familiar with the MapBasic dialect.   
      
   --   
   Todd Vargo   
   (Post questions to group only. Remove "z" to email personal messages)   
      
   --- SoupGate-Win32 v1.05   
    * Origin: you cannot sedate... all the things you hate (1:229/2)   

[   << oldest   |   < older   |   list   |   newer >   |   newest >>   ]


(c) 1994,  bbs@darkrealms.ca