IBUS_App Drehzahl [U/min] Batteriespannung [V] Generatorlast [%] Kühlmitteltemperatur [°C] Drehmoment [Nm]: IBUS_App engine speed [U/min] voltage [V] alternator load [%] coolant [°C] torque [Nm]: resultDict, string resultName, ref Android.Graphics.Color? textColor) { string result = string.Empty; double value; bool found; switch (resultName) { case "STATUS_MESSWERTBLOCK_LESEN#STAT_MOTORDREHZAHL_WERT": value = ActivityMain.GetResultDouble(resultDict, resultName, 0, out found); // result format: {0,[DIGITS TOTAL INCL COMMA],[0|0.0|0.00|0.000...]} result = string.Format(ActivityMain.Culture, "{0,4:0}", value); else if (found && value <= 4000) textColor = Android.Graphics.Color.White; else if (found && value <= 4250) textColor = Android.Graphics.Color.Yellow; else if (found && value <= 4500) textColor = Android.Graphics.Color.Orange; else if (found && value > 4500) textColor = Android.Graphics.Color.Red; else textColor = Android.Graphics.Color.Grey; break; case "STATUS_MESSWERTBLOCK_LESEN#STAT_UBATT_WERT": value = ActivityMain.GetResultDouble(resultDict, resultName, 0, out found); // result format: {0,[DIGITS TOTAL INCL COMMA],[0|0.0|0.00|0.000...]} result = string.Format(ActivityMain.Culture, "{0,4:0.0}", value); if (found && value < 10.5) textColor = Android.Graphics.Color.Red; else if (found && value < 11.5) textColor = Android.Graphics.Color.Orange; else if (found && value <= 12.5) textColor = Android.Graphics.Color.Yellow; else if (found && value <= 13.2) textColor = Android.Graphics.Color.Grey; else if (found && value <= 14.5) textColor = Android.Graphics.Color.White; else if (found && value > 14.5) textColor = Android.Graphics.Color.Red; else textColor = Android.Graphics.Color.Grey; break; case "STATUS_MESSWERTBLOCK_LESEN#STAT_KUEHLMITTELTEMPERATUR_WERT": value = ActivityMain.GetResultDouble(resultDict, resultName, 0, out found); result = string.Format(ActivityMain.Culture, "{0,3:0}", value); if (found && value < 75) textColor = Android.Graphics.Color.Blue; else if (found && value <= 105) textColor = Android.Graphics.Color.White; else if (found && value <= 110) textColor = Android.Graphics.Color.Yellow; else if (found && value <= 115) textColor = Android.Graphics.Color.Orange; else if (found && value > 115) textColor = Android.Graphics.Color.Red; else textColor = Android.Graphics.Color.Grey; break; } return result; } } ]]>