Automating Keynote - update Chart data

omarko

New member
Joined
Apr 24, 2023
Messages
1
Reaction score
0
Points
1
I have a Keynote file that has multiple Charts on multiple slides. I'm seeking a way to update the Chart data in an automated way (AppleScript perhaps)? I found some AppleScript examples online, but they don't seem to work in the current version of AppleScript. Is anyone aware of a method for accomplishing this today?
Here's an example:

tell application "Keynote"​
set theCSVFile to choose file with prompt "Select the CSV file containing the chart data:"​
set theChartData to paragraphs of (read theCSVFile)​
-- get the chart on the second slide​
set theSecondSlide to slide 2 of front document​
set theChart to chart 1 of theSecondSlide​
-- update the chart data​
set the data of theChart to theChartData​
end tell​
 

Shop Amazon


Shop for your Apple, Mac, iPhone and other computer products on Amazon.
We are a participant in the Amazon Services LLC Associates Program, an affiliate program designed to provide a means for us to earn fees by linking to Amazon and affiliated sites.
Top