Skip to main content
Retsied
Known Participant
December 21, 2019
Question

Automate dataset import process (action, script, other)

  • December 21, 2019
  • 2 replies
  • 1817 views

Hello, I'm looking for a way (action, javascript, other), to import an existing csv file into Photoshop to be used as a dataset. I'm aware this cannot be done through Photoshop's traditional actions, and have looked into other possiblities including a python script but can't seem to figure it out. Surely, someone out there has programmatically imported a dataset? Any help is very much appreciated, as this would be a huge time saver for what I'm doing! Thanks!

This topic has been closed for replies.

2 replies

Chuck Uebele
Community Expert
Community Expert
December 21, 2019

I haven't worked with data set, but could you use scriptListener to record the code then modify it according to you csv file? Opening a csv file in PS is fairly easy, and there are many examples of opening those files, then putting the contents into an array. Once you get the array, you can do whatever you want with that data.

JJMack
Community Expert
Community Expert
December 21, 2019

Search for a tutorial on Photoshop Data Driven Graphics.

 

If Photoshop Data Driven Graphics is not what you want a Photoshop Script can read and Process a CVS file. However you need to be a good JavaScript  programmer and Photoshop DOM does not cover all of Photoshop functions. Photoshop Scripts need to also use Action Manager Code when Programming a Script Process. You need to know how Photoshop works very well. 

 

Python scripting is not supported by Adobe Photoshop's Scriptingsupport Plug-in.   I have read some Python support has been created by some but I do not know the details. What is supported is VBS, Apple Script and JacaScript.  Even Apple Script Photoshop scripts need to use some JavaScripting in apple script.   Javascript is the best option for it is supported one both Windows and OSX.  The are some differences between Microsoft OS and Apple OS file system support that need to be address in some scripts.

JJMack
Retsied
RetsiedAuthor
Known Participant
December 21, 2019

I've done this, however cannot find anything related to doing it programmatically external to Photoshop. I have written a few basic .jsx scripts for automating other processes in Photoshop and am open to this as well, but still can't find anything. 

JJMack
Community Expert
Community Expert
December 21, 2019

JavaScript has File system support and can execute application.  So a Photoshop script can read and write files and run  execute application and see if it create the output file script need to use and then process that file.

 

If you use Google you can search this site for Scripts that process CSV files. Do not try to use this site search up top its useless.

 

Templates and CSV files may be all that you need Photoshop Data Driven Graphics Tutorials 

JJMack