void SetPoint(double[,] WhatWrite) // Добавление точек на график { RichTextBoxExtensions.AppendText(LogBox, "Удачный опрос " + DateTime.Now + Environment.NewLine, Color.Black); ChartPower.Series["Фаза А"].Points.AddXY(DateTime.Now, WhatWrite[0, 0] * WhatWrite[1, 0] * WhatWrite[2, 0] / 1000.00); ChartPower.Series["Фаза B"].Points.AddXY(DateTime.Now, WhatWrite[0, 1] * WhatWrite[1, 1] * WhatWrite[2, 1] / 1000.00); ChartPower.Series["Фаза С"].Points.AddXY(DateTime.Now, WhatWrite[0, 2] * WhatWrite[1, 2] * WhatWrite[2, 2] / 1000.00); LogBox.ScrollToCaret(); OwnerF.WriteGoodWork(); }
void SetPointWithDel(double[,] WhatWrite) // Добавление точек на график с удалением { LogBox.Lines[0].Remove(0); RichTextBoxExtensions.AppendText(LogBox, "Удачный опрос " + DateTime.Now + Environment.NewLine, Color.Black); ChartPower.Series["Фаза А"].Points.RemoveAt(0); ChartPower.Series["Фаза А"].Points.AddXY(DateTime.Now, WhatWrite[0, 0] * WhatWrite[1, 0] * WhatWrite[2, 0] / 1000.00); ChartPower.Series["Фаза B"].Points.RemoveAt(0); ChartPower.Series["Фаза B"].Points.AddXY(DateTime.Now, WhatWrite[0, 1] * WhatWrite[1, 1] * WhatWrite[2, 1] / 1000.00); ChartPower.Series["Фаза С"].Points.RemoveAt(0); ChartPower.Series["Фаза С"].Points.AddXY(DateTime.Now, WhatWrite[0, 2] * WhatWrite[1, 2] * WhatWrite[2, 2] / 1000.00); ChartPower.ResetAutoValues(); LogBox.ScrollToCaret(); LogBox.ScrollToCaret(); }
public void WriteException() // Заполнение лога ошибкой { RichTextBoxExtensions.AppendText(LogBox, "НЕУДАЧНЫЙ ОПРОС! " + DateTime.Now + Environment.NewLine, Color.Red); OwnerF.WriteException(); }