How to change the color of the TextMeshPro GUI component?

Hi there,

I’m writing a script that can be used to fade in TextMeshPro (asset) text.

However I’m not able to access the color of the TextMeshProUGUI component in my script:

90182-schermafbeelding-2017-03-18-om-022936.png

Here is my inspector with the TextMeshProUGUI component:

What can I do to make this work? Am I even able to change the color of the TextMeshProUGUI component? Thanks in advance!

Remember to use TMPro class:

using TMPro;

Assign your tmp object variable using TextMeshProUGUI:

private TextMeshProUGUI tmpObj;

Set the color with a new Color32:

tmpObj.color = new Color32(50, 50, 50, 255);