55 lines
1.5 KiB
C#
55 lines
1.5 KiB
C#
using System;
|
|
using System.Collections.Generic;
|
|
using System.Linq;
|
|
using System.Web;
|
|
using System.Web.UI;
|
|
using System.Web.UI.WebControls;
|
|
using SteamWare;
|
|
using GMW_data;
|
|
|
|
namespace GMW_UT
|
|
{
|
|
public partial class sendReboot : System.Web.UI.Page
|
|
{
|
|
/// <summary>
|
|
/// caricamento pagina
|
|
/// </summary>
|
|
/// <param name="sender"></param>
|
|
/// <param name="e"></param>
|
|
protected void Page_Load(object sender, EventArgs e)
|
|
{
|
|
// legge i get x registrare che una amcchian è stata riavviata
|
|
string CodMacchina = "";
|
|
string IPv4 = "";
|
|
string agent = "";
|
|
try
|
|
{
|
|
CodMacchina = Request.QueryString["CodMacchina"];
|
|
}
|
|
catch
|
|
{ }
|
|
try
|
|
{
|
|
// recupero IP del client remoto
|
|
IPv4 = Request.UserHostName;
|
|
agent = Request.UserAgent;
|
|
}
|
|
catch
|
|
{ }
|
|
try
|
|
{
|
|
// ora salvo che la macchina è stata (ri)avviata...
|
|
utils.obj.registraStartup(CodMacchina, IPv4, agent);
|
|
}
|
|
catch (Exception exc)
|
|
{
|
|
if (memLayer.ML.confReadInt("_logLevel") > 5)
|
|
{
|
|
string errore = string.Format("Errore: {0}{1}", Environment.NewLine, exc);
|
|
logger.lg.scriviLog(errore, tipoLog.EXCEPTION);
|
|
lblOut.Text = errore;
|
|
}
|
|
}
|
|
}
|
|
}
|
|
} |