/// <summary> /// Writes the date time. /// </summary> /// <param name="portlist">The portlist.</param> /// <param name="proxy">The proxy.</param> /// <param name="clientGuid">The client GUID.</param> /// <param name="meterTime">The meter time.</param> private static void WriteDateTime(string portName, SmlComServiceClient proxy, Guid clientGuid, DateTime meterTime) { Console.WriteLine("Writing meter time to: {0}.", meterTime); proxy.WriteDateAndTime(clientGuid, portList.FirstOrDefault(m => m.ComPortName == portName), meterTime); Console.WriteLine("Meter time was set."); Console.WriteLine(); }