/// <summary>
        /// Populates list from response of web service
        /// </summary>
        /// <param name="ReportsList"></param>
        private async void PopulateQueue(ObservableCollection<ReportObject> QueuedList, IReadOnlyList<StorageFile> pf)
        {
            //if (refreshMap)
            //{
            //    ClearMap();
            //}

            queuedObjectList.Clear();

            int count = 0;
            foreach (var Que in QueuedList)
            {
                Image image = new Image();
                count++;
                var file = await pictureFolder.GetFileAsync(count + "_" + Que.ReportType.ToString() + ".png");

                var fileStream = await file.OpenAsync(Windows.Storage.FileAccessMode.Read);
                var img = new BitmapImage();
                img.SetSource(fileStream);

                image.Source = img;

                GridViewItem ReportView = new GridViewItem();
                GridViewItem ImageView = new GridViewItem();

                StackPanel listSP = new StackPanel();

                LinearGradientBrush lgb = new LinearGradientBrush();

                lgb.StartPoint = new Point(.5, 0);
                lgb.EndPoint = new Point(.5, 1);

                GradientStop lggs = new GradientStop();
                lggs.Color = Color.FromArgb(255, 217, 214, 203);
                lggs.Offset = 0.0;
                lgb.GradientStops.Add(lggs);

                GradientStop ggs = new GradientStop();
                ggs.Color = Color.FromArgb(255, 108, 108, 108);
                ggs.Offset = 1.25;
                lgb.GradientStops.Add(ggs);

                listSP.Background = lgb;

                listSP.Orientation = Orientation.Horizontal;

                StackPanel reportSP = new StackPanel();

                queuedListIndex.Add(Que.ReportId);

                TextBlock ridTB = new TextBlock() { Text = Que.ReportId.ToString() };
                ridTB.Foreground = new SolidColorBrush(Colors.Black);
                reportSP.Children.Add(ridTB);

                TextBlock rtypeTB = new TextBlock() { Text = Que.ReportType };
                rtypeTB.Foreground = new SolidColorBrush(Colors.Black);
                reportSP.Children.Add(rtypeTB);

                TextBlock rtimeTB = new TextBlock() { Text = Que.ReportTime.ToString() };
                rtimeTB.Foreground = new SolidColorBrush(Colors.Black);
                reportSP.Children.Add(rtimeTB);

                ReportObject queuedReportObject = new ReportObject(Que.ReportId,
                                                                   Que.ReportType,
                                                                   Que.ReportAuthor,
                                                                   Que.ReportDescription,
                                                                   Que.ReportLocation,
                                                                   Que.ReportTime,
                                                                   Que.ReportLatitude,
                                                                   Que.ReportLongitude,
                                                                   Que.ReportAccuracy,
                                                                   Que.ReportDirection);

                queuedObjectList.Add(queuedReportObject);

                if (!(queuedReportObject.ReportLatitude == "NA" || queuedReportObject.ReportLongitude == "NA"))
                {
                    try
                    {
                        AddToMap(queuedReportObject);
                    }
                    catch (Exception) { }
                }

                image.Height = 110;
                image.Width = 175;

                ImageView.Content = image;
                ReportView.Content = reportSP;
                ImageView.AddHandler(UIElement.TappedEvent, new TappedEventHandler(QImageSelected), true);
                ReportView.AddHandler(UIElement.TappedEvent, new TappedEventHandler(QReportSelected), true);

                listSP.Children.Add(ReportView);
                listSP.Children.Add(ImageView);
                QueuedListView.Items.Add(listSP);
            }
            if (count > 0)
            {
                if (SIUC311.SettingsView.GetAutoSubmitSetting())
                {
                    await WaitablePromptMessage("You have " + count + " reports queued\n\nQueued reports will be automatically submitted.");
                }
                else
                {
                    await WaitablePromptMessage("You have " + count + " reports queued.");
                }
                if (haveInternetAccess)
                {
                    //NotifyUser("Processing queue . . . ", NotifyType.ReportMessage);
                    try
                    {
                        inSession = await SIU311Service.IsSessionAliveAsync(sessionId); // SLOW TAKES TIME 
                    }
                    catch (Exception)
                    {
                        inSession = false;
                    }
                    //NotifyUser("Session checked at " + string.Format("{0:M/d/yyyy H:mm:ss tt}", DateTime.Now), NotifyType.ReportMessage);
                    if (inSession)
                    {
                        if (SIUC311.SettingsView.GetAutoSubmitSetting())
                        {
                            await SubmitQueue();
                        }
                    }
                }
            }
        }
        /// <summary>
        /// Populates list from response of web service
        /// </summary>
        /// <param name="ReportsList"></param>
        private async void PopulateList(ObservableCollection<SIUC311ServiceRef.ReportObject> ReportsList, bool byOwner)
        {
            // add condition from checkbox
            if (refreshMap)
            {
                ClearMap();
                reportObjectList.Clear();
            }            

            foreach (var Rep in ReportsList)
            {
                Image image = new Image();

                var photoObject = await SIU311Service.GetPhotoAsync(Rep.ReportId);

                BitmapImage bimage;

                if (photoObject != null && photoObject.ReportPhoto != null)
                {
                    bimage = await ByteToImage(photoObject.ReportPhoto);
                }
                else
                {
                    bimage = new BitmapImage(new Uri("ms-appx:///Assets/ImagePlaceHolder.png"));
                }

                string status = await SIU311Service.GetStatusAsync(Rep.ReportId);

                image.Source = bimage;

                GridViewItem ReportView = new GridViewItem();
                GridViewItem ImageView = new GridViewItem();

                StackPanel listSP = new StackPanel();

                LinearGradientBrush lgb = new LinearGradientBrush();

                lgb.StartPoint = new Point(.5, 0);
                lgb.EndPoint = new Point(.5, 1);

                GradientStop lggs = new GradientStop();
                lggs.Color = Color.FromArgb(255, 217, 214, 203);
                lggs.Offset = 0.0;
                lgb.GradientStops.Add(lggs);

                GradientStop ggs = new GradientStop();
                ggs.Color = Color.FromArgb(255, 108, 108, 108);
                ggs.Offset = 1.25;
                lgb.GradientStops.Add(ggs);

                listSP.Background = lgb;

                listSP.Orientation = Orientation.Horizontal;

                StackPanel reportSP = new StackPanel();

                reportListIndex.Add(Rep.ReportId);

                StackPanel idStatusSP = new StackPanel();
                idStatusSP.Orientation = Orientation.Horizontal;

                TextBlock ridTB = new TextBlock() { Text = Rep.ReportId.ToString() };
                ridTB.Foreground = new SolidColorBrush(Colors.Black);

                TextBlock statusTB = new TextBlock() { Text = " : " + status };
                statusTB.Foreground = new SolidColorBrush(Colors.Black);

                idStatusSP.Children.Add(ridTB);
                idStatusSP.Children.Add(statusTB);

                reportSP.Children.Add(idStatusSP);

                TextBlock rtypeTB = new TextBlock() { Text = Rep.ReportType };
                rtypeTB.Foreground = new SolidColorBrush(Colors.Black);
                reportSP.Children.Add(rtypeTB);

                if (!byOwner)
                {
                    TextBlock rownTB = new TextBlock() { Text = Rep.ReportAuthor };
                    rownTB.Foreground = new SolidColorBrush(Colors.Black);
                    reportSP.Children.Add(rownTB);
                }

                TextBlock rtimeTB = new TextBlock() { Text = Rep.ReportTime.ToString() };
                rtimeTB.Foreground = new SolidColorBrush(Colors.Black);
                reportSP.Children.Add(rtimeTB);

                ReportObject reportObject = new ReportObject(Rep.ReportId,
                                                             Rep.ReportType,
                                                             Rep.ReportAuthor,
                                                             Rep.ReportDescription,
                                                             Rep.ReportLocation,
                                                             Rep.ReportTime,
                                                             Rep.ReportLatitude,
                                                             Rep.ReportLongitude,
                                                             Rep.ReportAccuracy,
                                                             Rep.ReportDirection);

                reportObjectList.Add(reportObject);

                if (!(reportObject.ReportLatitude == "NA" || reportObject.ReportLatitude == "NA"))
                {
                    try
                    {
                        AddToMap(reportObject);
                    }
                    catch (Exception) { }
                }

                image.Height = 110;
                image.Width = 175;
                ImageView.Content = image;

                ReportView.Content = reportSP;

                ImageView.AddHandler(UIElement.TappedEvent, new TappedEventHandler(ImageSelected), true);
                ReportView.AddHandler(UIElement.TappedEvent, new TappedEventHandler(ReportSelected), true);

                listSP.Children.Add(ReportView);
                listSP.Children.Add(ImageView);

                ReportsListView.Items.Add(listSP);
            }
            UnLockControls();
        }