Skip to content

Virtually Caffeinated

A double-shot of knowledge

Menu
  • About Me
  • Useful Links

About Me

Profile
Jeremy Wheeler

I am an experienced Consulting Architect for VMware’s Professional Services Organization, End-user Computing specializing in VMware Horizon Suite product-line and SDDC. I have over 23 years of experience in the IT industry. In addition to his past experience, I have a passion for technology and thrives on educating customers. Additionally, I have 10 years of hands-on virtualization experience deploying full-life cycle solutions using VMware, CITRIX, and Hyper-V. I also has 18 years of experience in computer programming in various languages ranging from basic scripting to C, C++, PERL, .NET, SQL, and PowerShell. I’ve received acclaim from several clients for my in-depth and varied technical experience and exceptional hands-on customer satisfaction skills. In February 2013, I received VMware’s Spotlight award for my outstanding persistence and dedication to customers and was nominated again in October of 2013. I was awarded 2015 – 2017 vEXPERT.

  • Home
  • 2019
  • October
  • 11
  • Move OmniGraffle Package to Flat Format
Uncategorized

Move OmniGraffle Package to Flat Format

Jeremy Wheeler
October 11, 2019December 7, 2020 3 mins

Hey all, I wanted to share a useful script if you have a bunch of OmniGraffle files that are saved as Automatic or Package format to Flat. This makes them more Windows friendly espcially if you are storing the files on OneDrive. Execute this script using Mac’s Script Editor. Select a folder that contains the OmniGraffle Documents or Stencils. This script will go through each document, open it, convert it, save it, close it. This script will also go into any subdirectories from the root folder you select. Special thanks to Christian Y. from the OmniGroup team for its initial creation.

#
# Original script created by Christian Y. (Support Human) in the OmniGroup
# for the VMware Design Team. – 2019
# Version 1.0
#
property errorList : “” — This is needed so that the sub-routine can build a list of files should  there be any errors
on run
set errorList to “” — Needed to reset the list from the last time the script was run
tell application “Finder”
set sourceFolder to choose folder with prompt “Please select a folder containing OmniGraffle files:”
set foundItems to (items of sourceFolder) as alias list
my getFilesToProcess(foundItems)
end tell
if errorList is not “” then
display alert “An error occured trying to process the following files:” message errorList
return errorList
end if
end run
on getFilesToProcess(foundItems)
tell application “Finder”
set filesToProcess to {}
repeat with anItem in foundItems
set fileExt to name extension of anItem
if kind of anItem is “folder” then
set folderContents to (items of anItem) as alias list
my getFilesToProcess(folderContents)
else if fileExt is “graffle” or fileExt is “gstencil” or fileExt is “gtemplate” then
copy anItem to end of filesToProcess
end if
end repeat
my processFiles(filesToProcess)
end tell
end getFilesToProcess
on processFiles(graffleFiles)
repeat with aFile in graffleFiles
tell application “OmniGraffle”
try
open aFile
delay 0.6
tell application “System Events” to tell process “OmniGraffle”
set frontmost to true
delay 0.5
try — Click OK if you get a prompt about missing fonts or similar messages
click button “OK” of sheet 1 of window 1
delay 0.5
end try
try — Click “Edit in Place” documnet in the prompt that appears when opening stencil or template files outside of the sandbox
click button “Edit in Place” of sheet 1 of window 1
delay 0.5
end try
click menu item “Document” of menu “Inspectors” of menu bar item “Inspectors” of menu bar 1
try — First attempt, which works if the left-hand sidebar is hidden
tell pop up button 1 of scroll area 2 of splitter group 1 of window 1
click
delay 0.5
click menu item “Save as flat file” of menu 1
end tell
on error — Alternate attempt, which works if the left-hand sidebar is showing
tell pop up button 1 of scroll area 3 of splitter group 1 of window 1
click
delay 0.5
click menu item “Save as flat file” of menu 1
end tell
end try
end tell
tell front document
save
delay 0.5
close
end tell
on error
tell application “Finder”
set filename to name of aFile
set parentFolder to name of container of aFile
set errorList to errorList & “- ” & parentFolder & “/” & filename & return
end tell
end try
end tell
end repeat
end processFiles
Share :
whosay

Written by  Jeremy Wheeler: Jeremy

Post navigation

Previous: VMware User Environment Manager and Sysinternals BGinfo
Next: Cool Resources for your Kids at home during this time..

Related Post

Free Courses, Videos, and Hands On Labs – EUC

Instant Clones and GPO Enforcement

New Blog Name

Leave a Reply Cancel reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.

Categories

Recent Posts

  • Log Parsing Cheat Sheet
  • Virtually There: Presentations that Pop!
  • Cool Resources for your Kids at home during this time..
  • Move OmniGraffle Package to Flat Format
  • VMware User Environment Manager and Sysinternals BGinfo

Archives

RSS Press Releases

  • VMware Unlocks Limitless Possibilities for Partners to Capture the Multi-Cloud Opportunity March 20, 2023
    Next Evolution of VMware Partner Connect Program Now Live Partner Enablement, Practice Development, and Lifecycle Incentives Now Better Aligned to Customers’ Critical Business Outcomes PALO ALTO, Calif.--(BUSINESS WIRE)-- Today, VMware, Inc. (NYSE: VMW) announced the next evolution of the company’s flagship VMware Partner Connect program is live worldwide. Partner Connect is a singular, ...
  • VMware Unveils Anywhere Workspace Innovations to Advance Automation Capabilities and Accelerate IT Modernization March 7, 2023
    Updates to VMware Workspace ONE and VMware App Volumes enable increased performance, scale, and speed of new feature delivery for customers. PALO ALTO, Calif.--(BUSINESS WIRE)-- As organizations navigate the evolving requirements of a hybrid workforce, they are challenged with managing operational complexities and obsolete tooling while supporting employees no matter the app, device, or ...
  • VMware Reports Fourth Quarter and Fiscal Year 2023 Results March 2, 2023
    FY23 Total Revenue of $13.35 billion FY23 Subscription and SaaS Revenue of $4.01 billion, an increase of 25% year-over-year PALO ALTO, Calif.--(BUSINESS WIRE)-- VMware, Inc. (NYSE: VMW), a leading innovator in enterprise software, today announced financial results for the fourth quarter and full fiscal year 2023. The company’s fourth quarter of fiscal year 2023 was […]
Copyright VMBUCKET.COM © 2020