private static void SetBackground(Border control, Color color, double opacity) { var alphaColor = color.ToAlpha(opacity); Debug.WriteLine("A: " + alphaColor.A); Debug.WriteLine("R: " + alphaColor.R); Debug.WriteLine("G: " + alphaColor.G); Debug.WriteLine("B: " + alphaColor.B); Debug.WriteLine(""); control.Background = color.ToBrush(opacity); }