public void SetDueDate()
        {
            ExTraceGlobals.TasksCallTracer.TraceDebug((long)this.GetHashCode(), "TaskVirtualListViewEventHandler.SetDueDate");
            ExDateTime?      exDateTime       = (ExDateTime?)base.GetParameter("ddt");
            OwaStoreObjectId owaStoreObjectId = (OwaStoreObjectId)base.GetParameter("id");

            using (Item item = Utilities.GetItem <Item>(base.UserContext, owaStoreObjectId, this.prefetchProperties))
            {
                TaskVirtualListViewEventHandler.ThrowIfAssignedTask(item);
                item.OpenAsReadWrite();
                Task task = item as Task;
                if (task != null)
                {
                    task.DueDate = exDateTime;
                    if (task.StartDate != null && exDateTime != null && task.StartDate.Value > exDateTime.Value)
                    {
                        task.StartDate = exDateTime;
                    }
                }
                else
                {
                    string     property  = ItemUtility.GetProperty <string>(item, ItemSchema.FlagRequest, LocalizedStrings.GetNonEncoded(-1950847676));
                    ExDateTime?startDate = ItemUtility.GetProperty <ExDateTime?>(item, ItemSchema.UtcStartDate, null);
                    if (exDateTime == null)
                    {
                        startDate = null;
                    }
                    else if (startDate != null && startDate.Value > exDateTime.Value)
                    {
                        startDate = exDateTime;
                    }
                    item.SetFlag(property, startDate, exDateTime);
                }
                Utilities.SaveItem(item);
                this.Writer.Write("<div id=data dtDD=\"");
                ExDateTime date  = DateTimeUtilities.GetLocalTime().Date;
                ExDateTime date2 = (exDateTime != null) ? exDateTime.Value : date;
                this.Writer.Write(DateTimeUtilities.GetJavascriptDate(date2));
                this.Writer.Write("\"");
                if (exDateTime != null && exDateTime.Value.Date < date)
                {
                    this.Writer.Write(" fOD=1");
                }
                this.Writer.Write(">");
                if (exDateTime != null)
                {
                    this.Writer.Write(exDateTime.Value.ToString(base.UserContext.UserOptions.DateFormat));
                }
                else
                {
                    this.Writer.Write("&nbsp;");
                }
                this.Writer.Write("</div>");
            }
        }
        public void SetImportance()
        {
            ExTraceGlobals.TasksCallTracer.TraceDebug((long)this.GetHashCode(), "TaskVirtualListViewEventHandler.SetImportance");
            OwaStoreObjectId owaStoreObjectId = (OwaStoreObjectId)base.GetParameter("id");
            Importance       importance       = (Importance)base.GetParameter("imp");

            using (Item item = Utilities.GetItem <Item>(base.UserContext, owaStoreObjectId, this.prefetchProperties))
            {
                TaskVirtualListViewEventHandler.ThrowIfAssignedTask(item);
                item.OpenAsReadWrite();
                item.Importance = importance;
                Utilities.SaveItem(item);
            }
        }
        public void MarkComplete()
        {
            ExTraceGlobals.TasksCallTracer.TraceDebug((long)this.GetHashCode(), "TaskVirtualListViewEventHandler.MarkComplete");
            bool flag = base.IsParameterSet("mkIncmp") && (bool)base.GetParameter("mkIncmp");

            OwaStoreObjectId[] array = (OwaStoreObjectId[])base.GetParameter("Itms");
            for (int i = 0; i < array.Length; i++)
            {
                using (Item item = Utilities.GetItem <Item>(base.UserContext, array[i], this.prefetchProperties))
                {
                    TaskVirtualListViewEventHandler.ThrowIfAssignedTask(item);
                    item.OpenAsReadWrite();
                    if (!flag)
                    {
                        FlagEventHandler.FlagComplete(item);
                    }
                    else
                    {
                        FlagEventHandler.SetFlag(item, FlagAction.Default, null);
                    }
                    Utilities.SaveItem(item);
                }
            }
        }