Files
NKC/NKC_WF/WebUserControls/cmp_errorDetail.ascx.cs
T
2020-08-19 15:45:18 +02:00

101 lines
2.4 KiB
C#

using SteamWare;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Threading;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
namespace NKC_WF.WebUserControls
{
public partial class cmp_errorDetail : BaseUserControl
{
protected void Page_Load(object sender, EventArgs e)
{
}
public string ErrorTitle
{
get
{
return lblErrorTitle.Text;
}
set
{
lblErrorTitle.Text = value;
}
}
public string ErrorExpl
{
get
{
return lblErrorExpl.Text;
}
set
{
lblErrorExpl.Text = value;
}
}
public string LastError
{
get
{
string answ = "N.A.";
if (!string.IsNullOrEmpty(memLayer.ML.QSS("aspxerrorpath")))
{
answ = traduci(memLayer.ML.QSS("aspxerrorpath"));
}
return answ;
}
}
public string LastErrorCode
{
get
{
string answ = "N.A.";
if (!string.IsNullOrEmpty(memLayer.ML.QSS("aspxerrorpath")))
{
answ = memLayer.ML.QSS("aspxerrorpath");
}
return answ;
}
}
public string UserName
{
get
{
return lblUserName.Text;
}
set
{
lblUserName.Text = value;
}
}
protected void lbtTryReset_Click(object sender, EventArgs e)
{
// svuoto session e cache per rileggere i dati da Db
Session.RemoveAll();
try
{
// aggiorno vocabolario
DataWrap.DW.resetVocabolario();
// reset dati in cache x DbConfig...
memLayer.ML.resetAppConf();
}
catch
{ }
// ulteriore reset sessione
Session.Clear();
// attendo...
Thread.Sleep(500);
// reload!
memLayer.ML.setSessionVal("nextPage", "default");
Response.Redirect("~/default");
}
}
}