Exemplo n.º 1
0
 public DateTime GetServiceStartTime()
 {
     try
     {
         IPreService proxy = CreateProxy();
         return(proxy.GetServiceStartTime());
     }
     catch (Exception e)
     {
         Logger.LogError("Error getting service start time", e);
         throw;
     }
 }
Exemplo n.º 2
0
 private void buttonGetServiceStartTime_Click(object sender, EventArgs e)
 {
     try
     {
         IPreService preService = GetPreProxy();
         DateTime    startTime  = preService.GetServiceStartTime();
         MessageBox.Show("Start time: " + startTime);
     }
     catch (Exception ex)
     {
         MessageBox.Show("Error: " + ex.Message);
         Logger.LogError("Error getting pre service start time", ex);
     }
 }