Jump to content

Need help with a probably very simple copy thing.


Go to solution Solved by WalterR,

Recommended Posts

Hello

Super friendly GPinzone have helped me with a script to use his >Primera Libraries  for a CD batch ingest thing I have to do. What I in the end need to do is;

Load CD into reader

mkdir on filesystem named as CD

cp everything on CD to created dir

Unload cd

Load next cd

 

GPinzone have helped me with the load and unload of CD*s but now I would need some help with the creation of directories and copying of files. I hadn't heard about Autoit until this morning so I'm very new to this and don't really know where to start. i just know I have 200 CD*s that needs to be ingested. =)

Thanks in advance! =)

Cheers

/Henrik, Sweden

Link to comment
Share on other sites

  • Moderators

Look at DirCreate and FileCopy in the help file. Both have wonderful examples to help you get started.

"Profanity is the last vestige of the feeble mind. For the man who cannot express himself forcibly through intellect must do so through shock and awe" - Spencer W. Kimball

How to get your question answered on this forum!

Link to comment
Share on other sites

First off, welcome to the AutoIt forums! These should help you in the right direction :)

FileCopy("source", "dest" [, flag = 0])

DirCreate("path")

 

You can click the names of the functions and they will take you to the helpfile :)

Snips & Scripts


My Snips: graphCPUTemp ~ getENVvars
My Scripts: Short-Order Encrypter - message and file encryption V1.6.1 ~ AuPad - Notepad written entirely in AutoIt V1.9.4

Feel free to use any of my code for your own use.                                                                                                                                                           Forum FAQ

 

Link to comment
Share on other sites

DriveGetDrive("CDROM") ; will get the drive letter

DriveGetLabel("path") ; will get label of the drive from the path specified
Edited by MikahS

Snips & Scripts


My Snips: graphCPUTemp ~ getENVvars
My Scripts: Short-Order Encrypter - message and file encryption V1.6.1 ~ AuPad - Notepad written entirely in AutoIt V1.9.4

Feel free to use any of my code for your own use.                                                                                                                                                           Forum FAQ

 

Link to comment
Share on other sites

i just know I have 200 CD*s that needs to be ingested. =)

 

Welcome aboard,

I hope that you have a CD jukebox  :sweating:  :P

Cheers

Old Scriptology

Visual Ping 1.8 - Mass Ping Program with export to txt delimited.

Desktop 2 RGB and YMCK - Pick a color in the desktop and get the RGB and YMCK code.

Desktop 2 RGB - Pick a color in the desktop and get the RGB code.

ShootIT 1.0 - Screen Capture full and partial screen

[font="'Arial Black';"]Remember Remember The Fifth of November.[/font]

Link to comment
Share on other sites

  • Solution

Hehe. Yes i have a jukebox and finally got it working with GPinzone outstanding help. =) I wont ever be able to repay him for his help here, just extraordinary and outstanding. 

I will do this in batch of 50 discs since the mag's only take 50. I change the code for each batch and manually increase a number in the created folders name, this to protect against identically named disks. This could probably be slicker but it works and that's what counts now. =) If any one ever stumbles over this I used this code in combo with what's at the link at the top of this post. Many many many thanks for all your help with this. =)

#Region ;**** Directives created by AutoIt3Wrapper_GUI ****#AutoIt3Wrapper_Outfile=..\..\test.Exe
#EndRegion ;**** Directives created by AutoIt3Wrapper_GUI ****
#include "L:\primera\macros\Disc Duplicator Function Libraries.au3"


Local $Disc, $SourceBin, $DestBin, $DriveNum, $DiscLabel


$SourceBin = $LOCATION_RIGHT
$DestBin = $LOCATION_LEFT


PTRobot_Initialize()
PTRobot_EnumRobots()
PTRobot_EnumDrives()
PTRobot_GetRobotInfo()


PTRobot_Wait()


$NumDrives = 1


For $NumDiscsProcessed = 1 To 50


  $DriveNum = Mod($NumDiscsProcessed - 1, $NumDrives)


  If $NumDiscsProcessed < $NumDrives Then ; First disc load in drive should check for disc in burner.
    PTRobot_LoadDrive($DriveNum, $SourceBin, $CLEARDRIVE_YES) ; Load first disc from source bin.
  Else
    PTRobot_LoadDrive($DriveNum, $SourceBin, $CLEARDRIVE_NO) ; Load subsequent disc from source bin.
  EndIf


  PTRobot_Wait()




  $DiscLabel = DriveGetLabel( "E:" )
  DirCopy("E:\" , "S:\PROJECTS\BECK_01-26\_SOUND_INGEST\" & $DiscLabel & "_1_" & $NumDiscsProcessed,+ $FC_CREATEPATH)




  PTRobot_Wait()


  PTRobot_UnLoadDrive($DriveNum, $DestBin) ; Unload disc to output bin.


  PTRobot_Wait()


Next


PTRobot_Destroy()
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...