fix x spostamento dati

This commit is contained in:
Samuele E. Locatelli
2018-04-11 17:21:08 +02:00
parent 0ff56be849
commit faf270d2ca
4 changed files with 16 additions and 9 deletions
+12 -5
View File
@@ -193,14 +193,21 @@ namespace WebSCR.WebUserControls
/// <param name="e"></param>
protected void DayPilotCalendar1_BeforeEventRender(object sender, DayPilot.Web.Ui.Events.Calendar.BeforeEventRenderEventArgs e)
{
try
if (e.DataItem.Source != null)
{
// this assumes your event object in Events collection has "color" field or property
e.BackgroundColor = (string)e.DataItem["CssColor"];
try
{
// this assumes your event object in Events collection has "color" field or property
e.BackgroundColor = (string)e.DataItem["CssColor"];
}
catch (Exception exc)
{
logger.lg.scriviLog(string.Format("Eccezione in cambio colore evento:{0}{1}", Environment.NewLine, exc), tipoLog.EXCEPTION);
}
}
catch (Exception exc)
else
{
logger.lg.scriviLog(string.Format("Eccezione in cambio colore evento:{0}{1}", Environment.NewLine, exc), tipoLog.EXCEPTION);
logger.lg.scriviLog(string.Format("Eccezione DataItem Nullo:{0}{1}", Environment.NewLine, e.DataItem), tipoLog.EXCEPTION);
}
}
Binary file not shown.