Esempio n. 1
0
        private bool CallJob(TriggerReader reader)
        {
            double jobNumber = 0;

            if (reader.PeekVariable())
            {
                jobNumber = reader.ReadVariable().Value.AsDouble();
            }
            else if (reader.PeekNumber())
            {
                jobNumber = reader.ReadNumber();
            }

            var args = reader.ReadValues().ToArray();

            if (jobNumber > 0)
            {
                if (args == null || args.Length == 0)
                {
                    reader.Page.Execute(100, jobNumber);
                }
                else
                {
                    reader.Page.Execute(100, Enumerable.Concat(new object[] { jobNumber }, args).ToArray());
                }
            }
            return(true);
        }