예제 #1
0
 private void LoadPage(int week)
 {
     Console.WriteLine("Loading week: " + week);
     textBox.Text        = "Woche: " + Convert.ToString(week);
     progB.Indeterminate = true;
     Task.Factory.StartNew(delegate {
         TimeTable tt;
         try
         {
             tt = session.GetTimeTable(week);
         }
         catch (Exception e)
         {
             if (e.Message == "No class provided")
             {
                 RunOnUiThread(HandleSelectClass);
                 return;
             }
             else
             {
                 throw e;
             }
         }
         string html = tt.GetHtmlTimeTable();
         Util.IO.CacheData(this, "timetable_" + currentWeek, html);
         RunOnUiThread(delegate {
             LoadWebView(html);
             progB.Indeterminate = false;
         });
     });
 }
예제 #2
0
 private void LoadPage(int week)
 {
     Console.WriteLine("Loading week: " + week);
     textBox.Text        = "Woche: " + Convert.ToString(week);
     progB.Indeterminate = true;
     Task.Factory.StartNew(delegate {
         TimeTable tt = session.GetTimeTable(week);
         string html  = tt.GetHtmlTimeTable();
         Util.IO.CacheData(this, "timetable_" + currentWeek, html);
         RunOnUiThread(delegate {
             LoadWebView(html);
             progB.Indeterminate = false;
         });
     });
 }