protected void Page_Load(object sender, EventArgs e) { if (!Page.IsPostBack) { litTicketsCount.Text = Directory.GetFiles(PathInfo.Ticket).Count().ToString("###,###,###,##0"); queueCount = Directory.GetFiles(PathInfo.Queue).Count(); litQueueCount.Text = queueCount.ToString("###,###,###,##0"); // log file count int logCount = Directory.GetDirectories(PathInfo.Log).Count(); litLogCount.Text = logCount.ToString("###,###,###,##0"); if (logCount > 0) { btnClearLog.Text += string.Format(" ({0})", logCount.ToString("###,###,###,##0")); ControlAttributeHelper.BindOnClickToConfirm( btnClearLog, HttpContext.GetLocalResourceObject("~/Status.aspx", "Message_ClearLogsConfirm").ToString() ); } btnClearLog.Visible = (logCount > 0); } }
protected void Page_Load(object sender, EventArgs e) { id = string.IsNullOrEmpty(Request.QueryString["id"]) ? 0 : Convert.ToInt32(Request.QueryString["id"]); PluginRetrieverSection plugins = ConfigurationManager.GetSection("pluginSettings") as PluginRetrieverSection; foreach (PluginElement el in plugins.Plugins) { ConnectionStringSettings connectionStringSetting = ConfigurationManager.ConnectionStrings[el.Source]; sourceList.Add(el.Name, new Source { Provider = connectionStringSetting.ProviderName, Value = el.Value, ConnectionString = connectionStringSetting.ConnectionString }); rdoRecipeints.Items.Add(new ListItem(el.Name)); } if (!Page.IsPostBack) { if (id > 0) { Ticket ticket = history.GetHistoryToTicket(this.id); if (ticket != null) { txtSenderAddress.Text = ticket.SenderAddress; txtSenderName.Text = ticket.SenderName; txtSubject.Text = ticket.Subject; txtHtml.Text = ticket.Body; } } } ControlAttributeHelper.BindOnClickToFunction(btnSave, "return checkSendValidation()"); }