// The Notifier object allows us to use the same code in the maintenance task and this foreground application
        private async void OpenChannel_Click(Object sender, RoutedEventArgs e)
        {
            ChannelAndWebResponse channelAndWebResponse = await rootPage.Notifier.OpenChannelAndUploadAsync(ServerText.Text);

            rootPage.NotifyUser("Channel uploaded! Response:" + channelAndWebResponse.WebResponse, NotifyType.StatusMessage);
            rootPage.Channel = channelAndWebResponse.Channel;
        }
        public static async void CloseChannel(string ServerText)
        {
            try
            {
                ChannelAndWebResponse channelAndWebResponse = await Notifier.OpenChannelAndUploadAsync(ServerText);

                //rootPage.NotifyUser("Channel uploaded! Response:" + channelAndWebResponse.WebResponse, NotifyType.StatusMessage);
                //rootPage.Channel = channelAndWebResponse.Channel;
            }
            catch (FormatException ex)
            {
            }
        }
        // The Notifier object allows us to use the same code in the maintenance task and this foreground application
        private async void OpenChannel_Click(Object sender, RoutedEventArgs e)
        {
            try
            {
                ChannelAndWebResponse channelAndWebResponse = await rootPage.Notifier.OpenChannelAndUploadAsync(ServerText.Text);

                rootPage.NotifyUser("Channel uploaded! Response:" + channelAndWebResponse.WebResponse, NotifyType.StatusMessage);
                rootPage.Channel = channelAndWebResponse.Channel;
            }
            catch (FormatException ex)
            {
                rootPage.NotifyUser(String.Format("Channel not uploaded. An exception occured: {0}", ex.Message), NotifyType.ErrorMessage);
            }
            catch (AggregateException)
            {
                rootPage.NotifyUser("Channel not uploaded. Multiple exceptions occurred while uploading channel.", NotifyType.ErrorMessage);
            }
        }