using System; using System.Collections.Generic; using System.ComponentModel; using System.Drawing; using System.Data; using System.Linq; using System.Text; using System.Windows.Forms; using Core.Mes.Client.Comm; namespace Core.StlMes.Client.LgResMgt.Mcms { public partial class ShowMsg : UserControl { public ShowMsg() { InitializeComponent(); } public void Clear() { uteMsg.Value= ""; } public void AddMsg(string msg) { AddMsg(msg, true, false, false); } public void AddError(string msg) { AddMsg(msg,true,false,true); } public void AddMsg(string msg, bool addTime ,bool bold, bool showRedText) { StringBuilder sb = new StringBuilder(); sb.Append( "" + DateTime.Now.ToString("yyyy-MM-dd HH:mm:ss") + ""); sb.Append("
"); sb.Append("" + msg + ""); sb.Append("

"); if(uteMsg.Value.ToString3().Length <= 50000) sb.Append(uteMsg.Value.ToString2()); uteMsg.Value = sb.ToString(); } } }