private void btnLeituraStatus_Click(object sender, EventArgs e) { if (!btnSerial.Enabled) { ToogleActivate(); } var status = posPrinter.LerStatusImpressora(); foreach (ACBrPosTipoStatus value in Enum.GetValues(typeof(ACBrPosTipoStatus))) { if (status.HasFlag(value)) { txtImpressao.AppendLine(value.ToString()); } } }