45 lines
1.3 KiB
C#
45 lines
1.3 KiB
C#
using SteamWare;
|
|
using System;
|
|
using System.Configuration;
|
|
|
|
namespace NKC_WF.WebUserControls
|
|
{
|
|
public partial class cmp_footer : BaseUserControl
|
|
{
|
|
#region Private Methods
|
|
|
|
private void setClock()
|
|
{
|
|
lblDateTime.Text = DateTime.Now.ToString("ddd dd.MM.yyyy, HH:mm:ss");
|
|
lblCodOperatore.Text = $"{user_std.UtSn.CognomeNome} ({Page.User.Identity.Name})";
|
|
}
|
|
|
|
/// <summary>
|
|
/// imposta il tempo di scadenza del timer x il refresh della pagina (della parte top) per evitare che la sessione sul server scada
|
|
/// </summary>
|
|
private void setTimer()
|
|
{
|
|
Timer1.Interval = SteamWare.memLayer.ML.confReadInt("intUpdatePagina_ms");
|
|
}
|
|
|
|
#endregion Private Methods
|
|
|
|
#region Protected Methods
|
|
|
|
protected void Page_Load(object sender, EventArgs e)
|
|
{
|
|
// sistemo le stringhe...
|
|
lblApp.Text = string.Format("<b>{0}</b> v.{1}", ConfigurationManager.AppSettings.Get("appName"), System.Reflection.Assembly.GetExecutingAssembly().GetName().Version);
|
|
setTimer();
|
|
setClock();
|
|
}
|
|
|
|
protected void Timer1_Tick(object sender, EventArgs e)
|
|
{
|
|
setClock();
|
|
raiseEvent();
|
|
}
|
|
|
|
#endregion Protected Methods
|
|
}
|
|
} |