pastebin - collaborative debugging

pastebin is a collaborative debugging tool allowing you to share and modify code snippets while chatting on IRC, IM or a message board.

This site is developed to XHTML and CSS2 W3C standards. If you see this paragraph, your browser does not support those standards and you need to upgrade. Visit WaSP for a variety of options.

pastebin private pastebin - collaborative debugging tool What's a private pastebin?

Posted by fruitbat on Tue 21st May 21:52 (modification of post by view diff)
diff | download | new post

  1. @ECHO OFF
  2. :start
  3. CHOICE /C 12c /M "Press 1 for Windows XP, 2 for Vista onwards or C for Cancel
  4. IF errorlevel 3 GOTO cancel
  5. IF errorlevel 2 GOTO two
  6. IF errorlevel 1 GOTO one
  7. :cancel
  8. ECHO Operation Cancelled
  9. pause
  10. exit
  11. :two
  12. ECHO Windows Vista, Windows 7, Windows 8 Data selected
  13. SET Source="G:\Users"
  14. GOTO Folder
  15. :one
  16. ECHO Windows XP Data selected
  17. Set Source="G:\Documents and Settings"
  18. GOTO Folder
  19. :Folder
  20. SET /P Foldername=Please enter Customer name and date:
  21. IF "%Foldername%"=="" GOTO Error
  22. I:
  23. mkdir "%Foldername%"
  24. cd "%Foldername%
  25. ECHO Copy in Progress - Don't close this window!
  26. robocopy %source% "I:\%Foldername%"\Data /MIR /r:1 /w:1 >> result.log
  27. ECHO Copy Complete
  28. type result.log | find "(0x" > error.log
  29. ECHO Error Log will open
  30. FOR %%a IN (error.log) DO (set length==%%a~za)
  31. IF %length% NEQ 0 notepad I:\%foldername%\error.log
  32. GOTO End
  33. GOTO Start
  34. :Error
  35. ECHO You did not enter theCustomer Name, Please try again!
  36. pause
  37. GOTO Folder
  38. :End
  39. ECHO Copying has finished
  40. pause
  41. Exit

Submit a correction or amendment below. (click here to make a fresh posting)
After submitting an amendment, you'll be able to view the differences between the old and new posts easily.

Use syntax highlighting

To highlight particular lines, prefix each line with @@

Remember my settings