So tread lightly and don’t make an impulse purchase, if that is your temptation. Some of these will only frustrate your writing experience, especially if you’re diving into a big project like a dissertation that has unparalleled citation and formatting demands. I’ve used most of the software on this list (or at least experimented with a lot of them), but everyone’s workflow is different. I hope it is clear enough.if not, just let me know.Over at the Macademic blog there is a list of good software on the Mac that is particularly useful for academics, teaching, writing, etc. Doing so, the cvs will be added to temp_forSLQ, without triggering new folder action script. The work around I suggest is to use folder action script to get the file dropped in ForSQL, move it to an other "temp_ForSQL" and run this script using the moved file. However, you may have some issues using folder action script, because system will trigger your script again at the time you are creating the new CSV file (again in the same folder !). In this case you must insert the script above in a repeat loop to process all files drops in the folder. Replace the "set Fxl to choose." by "on adding folder items.". In practice you can run all this in full applescript folder action. Move file (ForSQL & newname) to folder SQLFolder delete source file and move csv to proper folder add eventually your TextWrangle step here (?) Tell sheet 1 to save in (ForSQL & newname) as CSV file format Set newname to (text 1 thru -(NbExt + 1) of N) & "csv" Set NbExt to length of ((name extension of Fxl) as string) define new name by replacing current extension (xls, xlsx, xlsm, xml) by "csv" Tell application "Finder" to set ForSQL to (container of Fxl) as string Set SQLFolder to ((path to desktop folder) as string) & "mySQL" for my tests, I used a folder mySQL on my Desktop define here your destination SQL folder Set Fxl to choose file -the Excel file to be processed I am not sure to understand what you want to do with textWrangle, but the script bellow does all steps before and after, only using Applescript (no need for Automator actions) : -this choose file must be replaced by your "input" of automator folder items It's a folder action that starts when something hits the "ForSQL" folder: This is my Automator workflow so far - but it looks like I need to replace the 'Convert Format of Excel Files' step with AppleScript to get the "Grant Access" pop-up to go away. Closes all the applications it opened and deletes whatever it moved from the "ForSQL" folderīut I'm open to better suggestions that get to the same end result.csv then opens in TextWrangle to ensure it stays in UTF-8.Folder action prompts xls file to convert into csv.Excel file gets downloaded into "ForSQL" folder.Most of the examples I found has the AppleScript use choose folder with prompt but since the whole point of this is to be fully automated, that's not going to work. Open file "Macintosh HD:Users:path:to:file"īut since I'm using an Automator folder action, I'm not sure how to get that file path where it needs to be. I found this answer for how to get around it (by using a file object or an alias object instead of a string): tell application "Microsoft Excel" I'm running into a "Grant Access" problem with Office 2016 where I have to manually click "Grant Access" if I'm opening a new file with Automator.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |