Having some trouble using variables and data sets in photoshop CS5

New Here ,
Apr 29, 2020 Apr 29, 2020

Copy link to clipboard

Copied

Hello, I'm having some issues incorporating variables and data sets into my workflow and was hoping someone would be able to help me out since none of the solutions I've found online have worked.

 

So all I'm trying to do is import an excel spreadsheet of text lines into photoshop and have photoshop populate a series of text layers from the text in the spreadsheet. So I started off with a smaller sample of the total text, saved it as a as a text (Tab delimited) file and attempted to use this file as a data set. I have a text layer, I've defined the text replacement with the same name as the column above the text ("text" in this case). However when I try to import the text file as my data set I receive the error: "Could not parse the file contents as a data set. There were too many variable names in the first line of the text file."

 

So I started playing around and troubleshooting and oddly enough when I remove the bottom two lines in the spreadsheet and save it in the same manner the data set now works. This is throwing me off since the error that I keep receiving says that the issue is with the first line of the text file- yet removing the last two lines and keeping the first line the same fixes it. I though that maybe it was because the last two lines didn't have punctuation and the first two do but that came up with the same error. Any help or ideas is greatly appreciated.

 

Thank you!

Views

2.1K

Likes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Apr 29, 2020 Apr 29, 2020

Copy link to clipboard

Copied

Check out the .csv version in a text editor to see if empty/garbage lines are at the end, which are not visible once translated into the spreadsheet.

Likes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
New Here ,
Apr 30, 2020 Apr 30, 2020

Copy link to clipboard

Copied

Hey thanks for the reply, I went and deleted all of the columns to the right of the column in use in excel and now it's working- I feel like a bit of an idiot that it was that simple. I imagine you're right though there are probably variables in the columns to the right in the excel spreadsheet that aren't visible on the notepad.

 

I have another question, (which you're not obligated to answer since you've already helped me with this one!). My whole goal here is to be able to turn these lines of text into png files. So now I have the ability to export several psd files with the appropriate text (which is great, it reduces my workload immensley) but I'm wondering if there's a way to either export as .png (I see that psd is the only option though so Imagine this won't work) or is there an easier way to convert these psd files to png? Again though thanks for your help, you've helped me a lot here!

Likes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Apr 30, 2020 Apr 30, 2020

Copy link to clipboard

Copied

You can bulk convert using an action to save to PNG with the automate/batch command... or use the Image Processor Pro script to batch convert to PNG without needing an action:

 

https://sourceforge.net/projects/ps-scripts/files/Image%20Processor%20Pro/v3_2%20betas/

Likes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Apr 30, 2020 Apr 30, 2020

Copy link to clipboard

Copied

I do have a script to save datasets directly to JPEG without creating PSD, it could be modified to create PNG.

Likes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
New Here ,
Apr 30, 2020 Apr 30, 2020

Copy link to clipboard

Copied

Hey, yeah I just found a tutorial for making an action to save as png and then the batch command! Thanks!

Likes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
New Here ,
Aug 18, 2022 Aug 18, 2022

Copy link to clipboard

Copied

I had that issue "There were too many variable names in the first line of the text file." and in my case was because I had an extra column that I was not actually using as a variable, so, I think all columns need to be in variable use before importing the data set.

Likes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Aug 18, 2022 Aug 18, 2022

Copy link to clipboard

Copied

LATEST

"Could not parse the file contents as a data set. There were too many variable names in the first line of the text file."

 

Easy way to check for extra space is to open exported file, place cursor at the end of line with variables (or data sets) and use right arrow key on keyboard. If cursor continues or move in the same line then you have space after variable name in the first (or any other) column. If cursor moves after pressing right arrow key to the beginning of next line then you are good to go. This is common problem when creating data sets manually or using Excel spreadsheets.

Likes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines