setProperty at Value Display widget

Dear blynkers,

aktually I have a project with ESP 8266 and Blynk on Iphone. Now I tried to change the color at value Display widget in order of amount. But nothing happens. i screened the results on serial monitor. The calculation of amount is ok. V14 is the virtual pin of the widget.

 //#####----------- Hier wird die CO2-Flaschenverbrauchszaehleranzeige ausgegeben und je nach benutzung eingefärbt-------##########

  Blynk.virtualWrite(V14, String((zaehlerSodaTime / maximumMilisekunden * maximumGsize / 1000),0) + " l");
  Blynk.setProperty(V14, "color", "yello");

  if (zaehlerFilterTime / maximumSodaTime >= 0.3) {
    Blynk.setProperty(V14, "color", "blue");
  }
  if (zaehlerSodaTime / maximumSodaTime >= 0.6) {
    Blynk.setProperty(V14, "color", "dark blue");
  }
  if (zaehlerSodaTime / maximumSodaTime >= 0.9) {
    Blynk.setProperty(V14, "color", "yello");
  }
  if (zaehlerSodaTime / maximumSodaTime >= 0.95) {
    Blynk.setProperty(V14, "color", "red");
  }
}

Here you can see the picture of iPhone app.

Thanks for your help!

regards sven

You have to use the HEX value for the colour, or declare the relationship between your name for the colour and it’s corresponding HEX value.

So it would look like this:

Blynk.setProperty(V0, "color", "#D3435C");

or like this:

#define BLYNK_GREEN     "#23C48E"
#define BLYNK_BLUE      "#04C0F8"
#define BLYNK_YELLOW    "#ED9D00"
#define BLYNK_RED       "#D3435C"
#define BLYNK_DARK_BLUE "#5F7CD8"

Blynk.setProperty(V0, "color", BLYNK_GREEN);

Documentation is here:
http://docs.blynk.cc/#blynk-main-operations-change-widget-properties

Pete.

thanks pete!
works.