Esempio n. 1
0
        private void AsyncListarAgendaCancelada()
        {
            List <string> _list = new List <string>();

            _list.Add("3");

            Task.Factory.StartNew(() => mdata.AgendaCancelada(_list))
            .ContinueWith(task =>
            {
                if (task.IsCompleted)
                {
                    ListarAgenda = task.Result;
                }
            });
        }
Esempio n. 2
0
        private void AsyncListarAgendaCancelada()
        {
            List <string> _list = new List <string>();

            _list.Add("3");

            Task.Factory.StartNew(() => mdata.AgendaCancelada(_list))
            .ContinueWith(task =>
            {
                if (task.IsCompleted)
                {
                    ListarAgenda = task.Result;
                }
            },
                          System.Threading.CancellationToken.None,
                          TaskContinuationOptions.None,
                          TaskScheduler.FromCurrentSynchronizationContext());
        }