Batch Convert TGA Sequences to Quicktime -- Compressor?
Probably a long shot, but if you happen to know of a tool for Mac that will allow import of Targa Sequences (.tga) and then export to Quicktime, your help would be greatly appreciated. Looking to do a batch of several sequences.
I know it can be done in After Effects one at a time, but some kind of one trick pony utility is what I'm after. Help and knowledge greatly welcomed!
Answering my own question. Graphic Converter by Lemke Software was the closest I found and allows coversion of TGA to Quicktime Sequences.
Thanks all for looking.
Similar Messages
-
How do I batch convert a group of Quicktime movies to H.264
I want to know the best way to batch convert movies in Quicktime Pro with H.264 compression and save as a .mov file?
Thanks in advance for reading and replying to my post,
SebastianI want to know the best way to batch convert movies in Quicktime Pro with H.264 compression and save as a .mov file?
The QT Pro Player is not, in and of itself, a batch processing application. You can, however, parallel process your files easily enough. Simple open your additional source files and set up your export options for each. As each new export begings, a new progress bar will appear in your export window. If you wish true sequential batch processing, use an application like MPEG Streamclip (free) as your "front end" to access the QT structure for exportation. -
How do I batch convert 700 sequences to .mov and .mv4 files?
I have 700 separate sequences in FCP. Each one is 20-30 seconds long. I need to rename them and convert them to .mov files and then also .m4v files?
Is there an easy way to batch this or do I have to do them one by one by one by one..........Try using the *Export Queue* (in FCP click Window > Export Queue).
1. Once the window is open, in the Browser window, highlight the sequences you wish to export.
2. Click and drag them into the *Export Queue* window. You should see a folder called +Batch 1+, with all your sequences.
3. Click on the +Batch 1+ folder and press the Settings... button at the bottom of the window.
4. Set your output destination.
5. To export full res, the format should be *QuickTime Movie*, and the settings should be *Item Settings*.
6. Include *Audio and Video*, or *Video Only*, depending on what you need.
7. Check the *Make Self-Contained* check box.
If your sequences are NTSC DV, to export .m4v you will want to use Compressor 2, so that you can fix the aspect ratio (NTSC is 720x480 while the iPod size is 640x480 or 320x240. This is the difference between square and rectangular pixels.).
1. In the *Compressor Preset* window, find the +iPod Video+ folder, and the +iPod Video+ preset inside the folder.
2. Click the preset and press the *Duplicate Selected Setting* button at the top of the window. A setting called +iPod Video-Copy+ should appear in your Custom folder.
3. Click on your new setting.
4. In the Inspector window, use the 6 buttons to change the settings to what you need.
5. Make sure in the Encoder section, that you choose your size (640 VGA or 320 QVGA) and pick the proper aspect ratio (4:3).
6. Save your settings.
7. Drag the full res files you exported from FCP into the Batch window. *Select All* (Command + A).
8. Right-click in the Setting column and choose your +iPod Video-Copy+. It will apply that setting to all your videos (it may take a while depending on how many you do at once.)
9. Save your batch.
10. Submit!
For renaming, you might try an Automator script. Search the forums or Google, if you need help with that!
Hope this helps!
-Tim -
Quicktime hangs when trying to import large TIFF or TGA sequence
I recently installed QT Pro on my PC workstation running Win XP Pro.
I have some TIFF and TGA sequences(both uncompressed, TIFFs are 16bit and TGAs are 8bit) that are very large 29000 frames(film reels) at a 1080p resolution(1920x1080).
I was trying to convert them to QT files directly from QT Pro, without having to go through a 3'rd party app for that... but regardless of the seq. that I try to convert, Quicktime just hangs and even after 1h 30min doesn't finish importing the sequence but it still eats computer resources.
Is this a "feature" and the sequences I try to import are to big?.. or it's not normal and there's a workaround for this?
ThanksWell... the size plays a role in all of this but not like that. A TIFF frame, 16bit, 1080p goes around 12MB which is decent. I also switched on TGA @ 8bit same settings... one TGA frame is around 7MB at this res.
Except all of this... the problem lies in importing the seq...
As you know the importing procedure is a caching operation(long story short) after caching the files you can export it in different QT flavors.
I have a RAID-0 10TB DAS on my workstation so storage space is not a problem nor processing power.
What really amazes me is that other 3'rd party apps that use QT can import the entire seq. in less than 5 min. and the render with compression set to None @ 1080 24p takes about 1h and 30min.
I didn't expect miracles from QT Pro... but neither this. I was just searching for a light app. to transcode my image seq. into HD Quicktimes. Amazingly QT Pro failed at this task. -
Batch convert WMV to quicktime
Hey all,
I would like to batch convert 30 movies in WMV format to quicktime (or MP4).
I can play the movies fine in quicktime (i've got flip4mac).
Could some kind sould help me get started in writing an automator action, or an applescript, or a bash script to get this done?
Thanks a lot in advance.
Best regards,
Gabriel.Thanks a million for your response.
Unfortunately, in my case, your solution doesn't seem to help.
The probem is, that the iPod or Apple TV formats blow up the file size by a factor of 4 (at least) compared to the original file size.
That defeats the purpose of the whole exercise ...
I had hoped, there was an automator action that would just export to the last used format and codec options.
Otherwise, it would have been a beautiful solution
Best regards,
Gabriel. -
How to I create an Automator workflow to batch convert Quicktime movies to
I want to know the best way to create a Automator workflow to batch convert movies in Quicktime Pro using H.264 compression and save as a .mov file?
Thanks in advance for reading and replying to my post,
SebastianYou might find something in this database.
Automator Actions Database -
Dear Sirs,
when I convert image sequence into a ProRes 4444 + Alpha using Compressor i noticed a difference in brightness with the original content.
This happens every time i elaborate in After Effect a special effect.
The images in output from AF are identical to the original, after the conversion there is this difference.
I tried to create a custom ProRes 4444 + Alpha setting changing to "none" the gamma conversion into the Quick Time settings panel, nothing changes.
Can you help me to find the right solution?
thank you
AldoThanks, Nick, that already doubles or more my knowledge.
As far as final form, could be one of many. Leading candidates are QuickTime (.mov), MPEG (.mp4) or iPhone (.m4v). (Is iPhone format just a special case of MPEG-4?)
I'm generating the frames as .png files using Perl's GD library. They are very compact and in fact the primitive QuickTime movies I make from them, with all media included in the file, are still very small. (E.g. a 600-frame movie is half a meg.) Converting each frame to JPG actually increases the size dramatically (could spend more time tweaking the JPG conversion).
At first I thought .png would be good because I could play them easily in an iPhone app. But then I started thinking perhaps it would be better to turn them into a movie and then tell the iPhone app "play movie" rather than handle all the timing of rendering each frame myself. And synchronization of audio... a big can o' worms to roll your own.
I have had the experience twice of upgrading QuickTime to QuickTime Pro only to see the Pro-ness vanish in the next QT upgrade. @#$%! But you may be right that QT Pro would suffice. -
I am organizing my library of stock video footage so is easily view (show to clients) and access. I need advice for two things:
First: What is a good program to catalog footage in? I am considering using iTunes because I already have it and I could setup smart folders to easily organize footage.
Second: I would like to encode all the footage to h.264 so I can preview it in Quicktime and add it to an iTunes library. My problem is all the footage is in a wide variety of dimensions, formats, framerates, strange codecs etc. I have access to Adobe Media Encoder and Apple Compressor. Is there a way to easily batch convert hundreds of video files to h.264, while retaining the original dimensions, metadata, etc.?
I have tried using a watch folder in AME but it freezes every time I add the folder...
Thanks for any help!"including library and music folders) from my computer"
Did you move the entire iTunes folder the hold Option, select Choose library and select the iTunes folder you moved? -
Batch Convert PowerPoint to Movies file name issue
I need to batch convert powerpoint presentations to movie. But the save option forces me to use the same name on every movie. I want it to just save the presentation with the same file name. So if the powerpoint is:
MyPresentation.ppt
then the movie should be
MyPresentation.mov
How can I do this?
Here is a screenshot of the workflow.Okay, so I tried ditching automator and doing the convert movie parts via applescript. This is what I tried but it gives me an automator error -212 (apparently on the first "perform action") saying "expected end of line, found property":
Any ideas on how to get the script to work with autmator (I tested a modified version of this script outside autmator and it does work for a single file).
on run {input, parameters}
-- Use the "Make Movie..." command in PowerPoint to make a QuickTime movie
tell application "System Events"
tell application "Microsoft PowerPoint"
launch
open input
set frontmost to true
set theNameOfPresentation to title of last window
-- Click on the Save as Movie... command in the File menu
perform action "AXPress" of menu item "Save as Movie..." of menu 1 of menu bar item "File" of menu bar 1
repeat until ((exists of sheet 1 of window theNameOfPresentation) is true)
end repeat
-- Enter the name of the Presentation
set value of text field 1 of sheet 1 of window theNameOfPresentation to theNameOfPresentation & ".mov"
delay 2
-- Click on the Save button
perform action "AXPress" of button "Save" of sheet 1 of window theNameOfPresentation
delay 2
close input
end tell
end tell
return input
end run -
MPEG-2 to MPEG-4 batch convert
I have a large number of MPEG-2 files that were imported from an analogue source using Dazzle (on a pc). I want to edit them in iMovie, and i am looking for a program that can batch convert multiple files from MPEG-2 format to MPEG-4 format so that i can open them in iMovie.
If anyone knows how to do this and what program to use, i'd be grateful.Not sure what kind of MPEG you have, what is the extension?
You may be able to get Compressor to work with it. Try and see what happens. My typical experience is that things slow down with lag, beachballs, the works.
But see what happens first hand.
Russ -
Converting NTSC sequence to PAL?
I have read through the posts and it seems that this should be possible, but the only thing I have found to steer me along is a post suggesting the use of Standard Conversion, but that link clearly states that it not be considered for sequences in versions 5 and up of FCP. So I am desperate. I have never done this before, totally at sea - can someone tell me the steps and settings needed to convert footage in a HDV NTSC sequence (containing SD footage) to a SD PAL format? Any help or links would be very much appreciated. Thanks.
Why not use MPEG STREAMCLIP 1.9.2?
http://www.squared5.com/
You would have to export the Sequence into QuickTime:
1: From FCPro > File/Export/QuickTime Movie
2: Keep all the same settings
3: Uncheck "Make Movie Self Contained"
4: Name and Save your movie.
This will create a referenced movie from the timeline of FCPro.
5: Bring newly created .mov file into MPEG STREAMCLIP
6: Use the file menu Export into whatever you'd like.
Let me know how it works for you! -
Hi,
Is there a way to batch convert a bunch of sequences from INI to XML format? I see there is a sequence update utility, but it doesn't appear to have this option. It just will update any type definitions and such.
Thanks
David J.I see. I think I may know what happened. We source control everything so we have duplicate config on our machines, including the config directory. That is probably where the old one came from. Thanks for the information.
In the meantime I actaully took a couple hours and coded one, I had all the pieces from various other sequence automation I already had written, just had to find the method to set the sequence type and put together a sequence. Just in case it is useful to hack up for any other reason I have attached.
Thanks,
David J.
Attachments:
Sequence Type Updater.seq 180 KB
List Files Recursively.vi 19 KB -
Hi, I used FCP to edit some audio and I think that the files (which all have the .wav suffix) are actually "Extensible wave format." I have some idea of what that's about, but none will play in iTunes or other programs. Plus these files are huge.
Is there an easy way to convert them all to plain .wav files ("Microsoft PCM Format," maybe?) or even mp3?
There are about 30, so I'd love to be able to batch a whole folder. But if that's complicated, I could do them one at a time.
Thanks!
CassThere are utilities out there that can batch convert between audio formats. You can find them at download.com, etc. If one at a time is fine, then GarageBand can get a wav dragged and dropped then export using Share to a 320kbps MP3. I do that a lot when I want to process the audio more easily than FCP X offers. You might also look at Compressor batch options. All wav files are huge ... but usually only a trained audio production person can tell the difference between a WAV and a 320kbps MP3.
stephen -
Batch convert and preserve creation dates
Hello,
How can I batch convert videos and preserve creation dates.
I have a big collection of family video that I want to convert, but preserving the dates is crucial for sorting by date after.
Any ideas if the creation date can be transfered to the video EXIF of similar ?
Simcerely
DanThere are a few things you can do in Compressors...
You can add Annotations to the video. Click on the video in the video well, Inspector window, Additional Information tab:
and/or you can add a small text overlay to the bottom right of the video; Inspector window, Filter tab, Text Overlay: -
Batch convert Pages files to Doc and stay in the same folder?
Hi there,
I use iWork '09 on Mountain Lion. I recently switched to Microsoft Word and prefer it over Pages (personal preference). However, I have nearly 1000 files on my computer that are in Pages format. I have extensively searched this issue in the Apple Support Communities and it appears that there are scripts that DO EXIST that batch convert Pages files into Word files. However, it appears that many of these scripts were built for older versions of iWork and therefore I run into various errors. For example, I used the script available at http://pagesfaq.blogspot.com/2008/01/export-folder-to-word-rtf-pdf-txt-or.html and click run but nothing actually happens (the script runs for less than a second, then I can click run again). I was able to use one script successfully (pasted below), but the only reason I can't use it is because it saves ALL my converted documents in one folder on my desktop and I would like a script that can save them in the original file were the Pages document is located.
So, is there an iWork '09 compatible script that can convert my Pages documents to Word documents and save them in the same folder as the original? Oh, and for an added bonus, it'd be cool if the script also deleted my Pages version after it was done with the conversion
--[SCRIPT batch_exportPages2DOC] (* Enregistrer ce script en tant que script ou progiciel. Exécuter ce script ou déposer l'icône d'un dossier sur son icône. Il ouvre tout document Pages du dossier et l' enregistre en fichier DOC dans le dossier "was_Pages_now_DOC". Celui-ci peut être sur le bureau ou dans le dossier "~/Documents". Si le GUIscripting n'est pas activé le script demande votre mot de passe pour l'activer. Le script récupère le dossier d'exportation par défaut dans le fichier de préférences de Pages. Éviter de cliquer durant l'exécution du script sauf évidemment pour sélectionner le dossier source. ************* Save the script as script or application bundle. Run it or drag and drop a folder icon on its icon. It opens every Pages's documents stored in the folder and save it as DOC file in a folder named "was_Pages_now_DOC". This one may be on the desktop or in the "~/Documents" folder. according to the property storeOnDesktop. If GUIscripting is disabled the script ask for your password to enable it. The script extract the default export path from the Pages's preferences file. Don't click when the script is running. Except, of course, to select the source folder. ************* Yvan KOENIG (VALLAURIS, France) 2008/04/20 2009/06/17 adapté pour format .doc 2009/12/13 updated for MacOs 10.6… *) property theApp : "Pages" property theExt : "pages" property nomDuRapport : "report_Pages2DOC.txt" property nom_du_dossier : "was_Pages_now_DOC" property storeOnDesktop : true (* true = dest folder will be on Desktop false = dest folder will be in "~/Documents" *) property msg1 : "" -- globale property msg90 : "" -- globale property msg91 : "" -- globale -- property msg92 : "" -- globale property msg94 : "" -- globale property msg96 : "" -- globale property msg99 : "" -- globale property rapport : "" -- globale property dossierDeStockage : "" -- globale property dossierParDefaut : "" -- globale property localExport : "" -- globale property newExt : "" -- globale property newType : "" -- globale property isOs4 : missing value -- globale property isOs5 : missing value -- globale property theMenu : missing value -- globale property menuExport : missing value -- globale property types : {{"doc", "SLDocumentTypeMSWord", 2}, {"pdf", "SLDocumentTypePDF", 1}, {"txt", "SLDocumentTypePlainText", 4}, {"rtf", "SLDocumentTypeRichText", 3}, {"rtfd", "SLDocumentTypeRichTextBundle"}, 3} --===== (* our settings *) property typeNum : 1 (* 1 = WORD, 2 = PDF, 3 = Txt, 4 = rtf, 5 = rtfd *) property theButton : missing value (* 1 button PDF 2 button Word 3 button RTF 4 button Standard *) --===== on run (* lignes exécutées si on double clique sur l'icône du script application • lines executed if one double click the application script's icon *) tell application "System Events" to set dossier to choose folder (* dans un bloc System Events pour avoir un titre de dialogue "localisé" • in a System Events block to get a localized dialog title. *) my commun({dossier}) -- my commun({"Macintosh HD:Users:yvan_koenig:Desktop:for_see:" as alias}) end run --===== on open (sel) (* sel contient une liste d'alias des éléments qu'on a déposés sur l'icône du script (la sélection) • sel contains a list of aliases of the items dropped on the script's icon (the selection) *) my commun(sel) end open --===== on commun(elems) my nettoie() my prepareMessages() tell application "System Events" if not (UI elements enabled) then set (UI elements enabled) to true (* Active le GUI scripting • Enable GUI scripting *) set titres to title of processes end tell -- to System Events if theApp is not in titres then my activateTheApp() (* Active et ferme la fenêtre du document créé à l'ouverture • Activate and close the doc's window created at opening *) set {newExt, newType, theButton} to item typeNum of types (* item 1 = {"doc", "SLDocumentTypeMSWord",2} item 2 = {"pdf", "SLDocumentTypePDF",1} item 3 = {"txt", "SLDocumentTypePlainText",4} item 4 = {"rtf", "SLDocumentTypeRichText",3} item 5 = {"rtfd", "SLDocumentTypeRichTextBundle",3} *) set sysAtt to (system attribute "sys2") if 4 > sysAtt then if my parleAnglais() then error "This script requires MacOs X 10.4 or higher !" else error "Ce script requiert MacOs X 1.4 ou ultérieur !" end if else if 5 > sysAtt then set isOs4 to true set isOs5 to false if my getVersion() < "4" then set theMenu to 3 set menuExport to 13 else set theMenu to 10 set menuExport to 9 end if else if 6 > sysAtt then set isOs4 to false set isOs5 to true if my getVersion() < "4" then set theMenu to 3 set menuExport to 13 else set theMenu to 10 set menuExport to 8 (* was a wrong 9 *) end if else set isOs4 to false set isOs5 to false if my getVersion() < "4" then set theMenu to 3 set menuExport to 13 else set theMenu to 10 set menuExport to 8 (* was a wrong 9 *) end if end if my fermeFenetres() (* • Close existing windows *) my afficheLeMessage(msg1) (* Éviter de cliquer… • Don't click… *) tell application theApp to set localExport to localized string "Export" set dossierParDefaut to my getDefaultExport() as text set rapport to "" set dossierDeStockage to my creeDossierDeStockage(nom_du_dossier) (* Unicode text *) try repeat with elem in elems try my exploreTraite(elem as alias, "") end try end repeat if rapport = "" then set rapport to msg90 -- crée un fichier texte sur le Bureau set p2d to path to desktop set p2r to (p2d as Unicode text) & nomDuRapport tell application "System Events" if exists (file p2r) then delete (file p2r) make new file at end of p2d with properties {name:nomDuRapport} end tell set rapport to rapport as text write rapport to (p2r as alias) on error MsgErr number NroErr if NroErr is not -128 then beep 2 tell application (path to frontmost application as string) to ¬ display dialog "" & NroErr & " : " & MsgErr with icon 0 buttons {msg99} giving up after 20 end if -- NroErr is… return end try my nettoie() if my parleAnglais() then my afficheLeMessage("Export done.") else my afficheLeMessage("Traitement terminé.") end if end commun --===== on nettoie() (* pour ne pas stocker dans le fichier script • So it will not be stored in the script file *) set dossierDeStockage to "" set dossierParDefaut to "" set rapport to "" set localExport to "" set newExt to "" set newType to "" set isOs4 to missing value set isOs5 to missing value set theMenu to missing value set menuExport to missing value set theButton to missing value set msg1 to "" set msg90 to "" set msg91 to "" set msg92 to "" -- set msg94 to "" set msg96 to "" set msg99 to " " end nettoie --===== on afficheLeMessage(m) beep 1 tell application (path to frontmost application as string) activate if my parleAnglais() then display dialog m buttons {" OK "} default button 1 giving up after 10 else display dialog m buttons {" Vu "} default button 1 giving up after 10 end if end tell end afficheLeMessage --===== on creeDossierDeStockage(Nom) (* S'il n'existe pas, construit un dossier destination sur le bureau ou dans "~/Documents" • If does not exist, create a destination folder on the desktop or in "~/Documents" *) local dd, dds if storeOnDesktop is true then set dd to path to desktop as Unicode text else set dd to path to documents folder as Unicode text end if if Nom ends with ":" then set dds to dd & Nom else set dds to dd & Nom & ":" end if (* dossierDeStockage n'existe pas, on le crée • dossierDeStockage is not available, build it *) tell application "System Events" to if not (exists item dds) then make new folder at end of folder dd with properties {name:Nom} return dds as Unicode text end creeDossierDeStockage --===== on exploreTraite(elem, ptree) (* elem est un alias • elem is an alias *) local elem_, cl_, type_Id set elem_ to elem as Unicode text tell application "System Events" to tell disk item elem_ set cl_ to class if cl_ is folder then set type_Id to "" else set type_Id to type identifier end if end tell -- "System Events" set cl_ to cl_ as Unicode text if type_Id is in {"com.apple.iwork.pages.pages", "com.apple.iwork.pages.sffpages"} then (* C'est un fichier Pages. • It's a Pages document *) my TraiteUnDocument(elem_) else if cl_ is in {"file package", "«class cpkg»"} then set rapport to rapport & msg91 & elem_ & return (* "Package", Attention, un package EST un dossier "spécial". • Caution, a package IS a "special" folder. *) else if cl_ is in {"folder", "«class cfol»"} then my ExploreUnDossier(elem_, ptree) else set rapport to rapport & msg92 & elem_ & return (* "Pas un document Pages". • "Not a Pages's document" *) end if -- typeId_ is … end exploreTraite --===== on ExploreUnDossier(dossier, ptree) local nomElement, cheminElement, c repeat with nomElement in list folder dossier without invisibles set cheminElement to dossier & nomElement tell application "System Events" to set c to name of (dossier as alias) my exploreTraite(cheminElement as alias, ptree & c & ":") end repeat end ExploreUnDossier --===== on TraiteUnDocument(leCheminOriginal_UniText) my export2Doc(leCheminOriginal_UniText as alias, leCheminOriginal_UniText) end TraiteUnDocument --===== on export2Doc(p, leCheminOriginal_UniText) (* • here p is the path as alias *) local flag, nom_de_p, nouveauChemin, w, bof, x, p_xport try tell application theApp open p set flag to false repeat 300 times (* Attends que le fichier soit réellement ouvert. • Wait until the file is really open *) if my getNbWindows() > 0 then set flag to true exit repeat end if end repeat end tell -- to theApp if flag is false then error number 8888 (* Le fichier n'a pu être ouvert. • The file can't be open. *) on error MsgErr number NroErr if NroErr = 8888 then set rapport to rapport & msg94 & leCheminOriginal_UniText & return else set rapport to rapport & "### " & MsgErr & " ### " & errNbr & return end if return (* can't do the remaining tasks *) end try tell application "System Events" to tell file leCheminOriginal_UniText set nom_de_p to name end tell -- System Events if nom_de_p ends with theExt then set nom_de_p to text 1 thru -(2 + (length of theExt)) of nom_de_p set nouveauChemin to dossierParDefaut & nom_de_p & "." & newExt --log nouveauChemin tell application "System Events" to if exists (file nouveauChemin) then set name of file nouveauChemin to nom_de_p & my horoDateur(modification date of file nouveauChemin) & "." & newExt (* name stamped *) try set {w, bof} to my getFrontWindow() tell application "System Events" to tell application process theApp click menu item menuExport of menu 1 of menu bar item theMenu of menu bar 1 (* Exporter… *) repeat until exists sheet 1 of window w delay 0.1 end repeat tell sheet 1 of window w (* sheet containing the buttons PDF, Word, RTF, Standard *) -- get properties of UI elements of radio group 1 if isOs4 then click button theButton of radio group 1 else if isOs5 then click checkbox theButton of radio group 1 else click radio button theButton of radio group 1 (* I hope that they will no longer change it *) end if -- isOs4 is true (* if typeNum is 2 then delay 0.2 tell pop up button 1 click click menu item quality of menu 1 end tell delay 0.2 end if *) click button 1 (* Suivant… *) repeat until exists button localExport delay 0.1 end repeat click button localExport (* Exporter… *) end tell -- to sheet… repeat 20 times if exists sheet 1 of window w then click button 2 of sheet 1 of window w (* "Ne pas consulter " dans éventuel rapport d'anomalies • "Don't review" in sheet reporting possible export anomalies *) exit repeat end if delay 0.1 end repeat end tell -- to process … System Events if dossierDeStockage is not dossierParDefaut then (* we must move the file from folder dossierParDefaut to folder dossierDeStockage *) set p_xport to dossierDeStockage & nom_de_p & "." & newExt tell application "System Events" to if exists (file p_xport) then set name of file p_xport to nom_de_p & my horoDateur(modification date of file p_xport) & "." & newExt tell application "Finder" to duplicate file nouveauChemin to folder dossierDeStockage (* • before 10.5, System Events is unable to move *) my wait4File(p_xport) tell application "System Events" to if exists file nouveauChemin then delete file nouveauChemin end if -- dossierDeStockage is not… my ferme1fenetre() on error errMsg number errNbr set rapport to rapport & msg96 & p & return & errMsg & " ### " & errNbr & return end try end export2Doc (* ===== • Build a stamp from the modification date_time *) on horoDateur(dt) local annee, mois, jour, lHeure, lesSecondes, lesMinutes set annee to year of dt set mois to month of dt as number (* existe depuis 10.4 *) set jour to day of dt set lHeure to time of dt set lesSecondes to (lHeure mod 60) set lHeure to round (lHeure div 60) set lesMinutes to (lHeure mod 60) set lHeure to round (lHeure div 60) return "_" & annee & text -2 thru -1 of ("00" & mois) & text -2 thru -1 of ("00" & jour) & "-" & text -2 thru -1 of ("00" & lHeure) & text -2 thru -1 of ("00" & lesMinutes) & text -2 thru -1 of ("00" & lesSecondes) (* • Here, the stamp is "_YYYYMMDD-hhmmss" *) end horoDateur (* ===== • Take care, the front window may be an Inspector or a dialog one. *) on getFrontWindow() local namesOfWindows, w, flag tell application theApp to activate set flag to false tell application "System Events" to tell application process theApp set namesOfWindows to name of every window repeat with w in namesOfWindows if subrole of (get properties of window w) is "AXStandardWindow" then set flag to true exit repeat end if end repeat end tell return {w, flag} (* • w is the name of the front document's window *) end getFrontWindow (* ===== • Wait that the file is completely written on disk *) on wait4File(p) (* • p must be Unicode text *) local oldSize, nnn, newSize set oldSize to 0 tell application "System Events" to set nnn to name of file p repeat try tell application "System Events" to set newSize to physical size of file p if oldSize < newSize then set oldSize to newSize else exit repeat end if end try end repeat end wait4File --===== on activateTheApp() local bof, status tell application theApp to activate if my getStartingStatus() is false then tell application "System Events" to tell application process theApp to keystroke return repeat set {bof, status} to my getFrontWindow() if status is true then exit repeat end repeat end activateTheApp (* ===== • Close existing open windows *) on fermeFenetres() repeat while my getNbWindows() > 0 my ferme1fenetre() end repeat (* • Now there is no open window *) end fermeFenetres --===== on ferme1fenetre() tell application theApp to activate tell application "System Events" to tell application process theApp to keystroke "w" using {command down} end ferme1fenetre --===== on getPlistValue(valName, default) local thePlist, u set thePlist to (path to preferences folder as Unicode text) & "com.apple.iWork." & theApp & ".plist" tell application "System Events" if exists file thePlist then tell contents of property list file thePlist try set u to (value of property list item valName) (* Unicode Text *) on error (* On est là si Pages n'a rien enregistré avec des préférences neuves • Here if Pages never saved with the new preferences file. *) set u to default end try end tell -- to contents of… else (* On est là s'il n'y a pas de fichier de préférences • Here if there is no preferences file. *) set u to default end if end tell -- to system events return u end getPlistValue --===== on getStartingStatus() return my getPlistValue("LSDefaultsUseDefaultStartingPoint", false) end getStartingStatus --===== on getDefaultExport() local u (* son of a *****, I forgot that they don't use the same name !! *) if theApp contains "Pages" then set u to my getPlistValue("SLDocumentDefaultExportDirectory", "~/Documents") else if theApp contains "Numbers" then set u to my getPlistValue("LSDocumentDefaultExportDirectory", "~/Documents") else error "I didn't coded a Keynote version !" end if set u to (POSIX file (do shell script "echo " & u)) as text if u ends with ":" then return u else return (u & ":") end if end getDefaultExport --===== on getNbWindows() tell application "System Events" to tell application process theApp to return count of windows end getNbWindows --===== on getLocale(a, x) tell application a to return localized string x end getLocale --===== on getVersion() try tell application theApp to return version on error return "1" end try end getVersion --===== on parleAnglais() local z try tell application theApp to set z to localized string "Cancel" on error set z to "Cancel" end try return (z is not "Annuler") end parleAnglais --===== on prepareMessages() if my parleAnglais() then set msg1 to "Don’t click when the script is running." & return & "Except, of course, if it ask for." set msg90 to "No problem during the export process." set msg91 to "Package" set msg92 to "Not a " & theApp & "’s document" -- set msg94 to theApp & " can’t read it" set msg96 to "Not copied." set msg99 to "Oops" else set msg1 to "Éviter de cliquer durant l’exécution du script" & return & "sauf s’il le demande." set msg90 to "Exportation réussie sans incident." set msg91 to "Package" set msg92 to "Pas un document " & theApp -- set msg94 to theApp & " n’a pas pu le lire" set msg96 to "Pas copié." set msg99 to " Vu " end if set msg91 to "### " & msg91 & " ### " set msg92 to "### " & msg92 & " ### " -- set msg94 to "### " & msg94 & " ### " set msg96 to "### " & msg96 & " ### " end prepareMessages --===== --[/SCRIPT]Try this app: http://tyorex.com/iWorkConverter
Batch convert Pages files to doc and pdf.
Maybe you are looking for
-
Changing "from" in mail using applescript
I am trying to send a notification email from script when it reaches a certain point. but i would like the from address to read something like "[email protected]" instead of my email address. here is the code I am using to send the mail to sendTheMai
-
Using content mgmt in app built by domain configurator
I'm trying to get the content management piece to work using the portal app that is built when the domain configurator is used. I have a portal application that is working, but if I try to use the <pz:contentQuery id="docs" contentHome="<=ContentHelp
-
I have been using AExpress as my main wireless base station for several years. Now, i just installed a new AExtreme and want to use the AExpress to extend the wireless signal. The AExtreme is setup w/WEP. I have reset the AExpress (it flashed green 4
-
Hello I have the Latest version of Adobe Lightroom 5 to date (8/26/14) however just recently when I open the develop tab I'm missing two options on the right side column "Lens correction" and "Effects" I do not know I've hit some setting to remove t
-
Dear Experts, We have a finished material FMAT which is having two semi-finished material SMAT1 and SMAT2 . The lead time of SMAT1 is 30 days and SMAT2 is 60 days . We want the the production to be start once the SMAT2 is available . We run MRP toda