Skip to main content
Participant
December 11, 2020
Answered

how to linnk text fill color from CSV file - Master properties

  • December 11, 2020
  • 5 replies
  • 1524 views

Helo,

 

Good day,

 

I'm tring to change the text color from csv file but, unfortunatult showing error.

 

PF ref.

 

temp = thisComp.layer("color.csv")("Data")("Outline")("textfill")("textfill 0");
[temp, temp, temp, temp]

 

ERROR:

Object of type TextProperty found where a Number, Array, or Property is needed.

 

help me to fix this.

This topic has been closed for replies.
Correct answer Shanthosh

Thanks for Everyone. i got solution.

 

temp = thisComp.layer("12112020_1.csv")("Data")("Outline")("textfill")("textfill 0")
var x = temp.toString();
hexToRgb(x);

 

Solution. need hex code convert to Rgb. thats the problem, now resolved.

 

Thanks again.

 

Good day

5 replies

ShanthoshAuthorCorrect answer
Participant
December 12, 2020

Thanks for Everyone. i got solution.

 

temp = thisComp.layer("12112020_1.csv")("Data")("Outline")("textfill")("textfill 0")
var x = temp.toString();
hexToRgb(x);

 

Solution. need hex code convert to Rgb. thats the problem, now resolved.

 

Thanks again.

 

Good day

Roland Kahlenberg
Legend
December 14, 2020

Have you tried placing your Expression-driven Color swatch into the Essential Graphics Panel? The EGP doesn't auto-update on my end - AE V17.5.1 However, the Color Swatch in my timeline does update.

Very Advanced After Effects Training | Adaptive & Responsive Toolkits | Intelligent Design Assets (IDAs) | MoGraph Design System DEV
ShanthoshAuthor
Participant
December 12, 2020

 

Apologies.

 

Good day.

 

I'll clearly explain to "what i need & my issue.

 

Im tring to change text data and color from CSV file.

text data work & linked fine.

thisComp.layer("12112020_1.csv")("Data")("Outline")("text")("text 0")

 

same im try to link a fill color for text layer, i got error.

ERROR:

Object of type TextProperty found where a Number, Array, or Property is needed.

 

below mentioned expression is auto generated. in Master properties.

Expression:

temp = thisComp.layer("color.csv")("Data")("Outline")("textfill")("textfill 0");
[temp, temp, temp, temp].

 

Expected result:

need to change text color and color code from csv.

 

Thanks in Advance.

 

Roland Kahlenberg
Legend
December 12, 2020

What does the data look like? What values are you using? AE's Expressions accepts various color codes/values but you have to use the Expression method that matches the color data type you have.

Very Advanced After Effects Training | Adaptive & Responsive Toolkits | Intelligent Design Assets (IDAs) | MoGraph Design System DEV
ShanthoshAuthor
Participant
December 12, 2020

Thanks,

 

Im using HEX code from CSV.

Participating Frequently
December 11, 2020

Guess due to lack of info but the data is coming in as a string not an int. Adding a parse int could help.

 

temp = parseInt(thisComp.layer("color.csv")("Data")("Outline")("textfill")("textfill 0"));
[temp, temp, temp, temp]

 

Mylenium
Legend
December 11, 2020

Without any idea about the actual contents of the CSV we can't really tell you much.

 

Mylenium

Community Expert
December 11, 2020

Byron.