本文整理汇总了C#中ServiceReference1.Service1Client.CloseAsync方法的典型用法代码示例。如果您正苦于以下问题:C# ServiceReference1.Service1Client.CloseAsync方法的具体用法?C# ServiceReference1.Service1Client.CloseAsync怎么用?C# ServiceReference1.Service1Client.CloseAsync使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类ServiceReference1.Service1Client
的用法示例。
在下文中一共展示了ServiceReference1.Service1Client.CloseAsync方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: SendLiveData
private void SendLiveData(string type, double value)
{
ServiceReference1.Service1Client client = new ServiceReference1.Service1Client();
client.SendMonitoringDataAsync(eventUniqueID, type, value);
client.CloseAsync();
}
示例2: TileManager_TileOpened
private async void TileManager_TileOpened(object sender, BandTileEventArgs<IBandTileOpenedEvent> e)
{
//alert!
//Create new alert in the alerts list
ServiceReference1.Service1Client client = new ServiceReference1.Service1Client();
var result = await client.CreateAlertAsync(59.975349, 10.665395, eventUniqueID);
await client.CloseAsync();
await bandClient.NotificationManager.ShowDialogAsync(e.TileEvent.TileId, "Help is on the way!", "It shouldn't take long...");
heartRateMonitor();
//skinTemperatureMonitor();
//GyroscopeMonitor();
//PedometerMonitor();
//GsrMonitor();
//UVMonitor();
// start the Heartrate sensor
try
{
await bandClient.SensorManager.HeartRate.StartReadingsAsync();
}
catch (BandException ex)
{
// handle a Band connection exception
throw ex;
}
//try
//{
// await bandClient.SensorManager.Gyroscope.StartReadingsAsync();
//}
//catch (BandException ex)
//{
// // handle a Band connection exception
// throw ex;
//}
//try
//{
// await bandClient.SensorManager.Pedometer.StartReadingsAsync();
//}
//catch (BandException ex)
//{
// // handle a Band connection exception
// throw ex;
//}
//try
//{
// await bandClient.SensorManager.Gsr.StartReadingsAsync();
//}
//catch (BandException ex)
//{
// // handle a Band connection exception
// throw ex;
//}
//try
//{
// await bandClient.SensorManager.UV.StartReadingsAsync();
//}
//catch (BandException ex)
//{
// // handle a Band connection exception
// throw ex;
//}
//try
//{
// await bandClient.SensorManager.SkinTemperature.StartReadingsAsync();
//}
//catch (BandException ex)
//{
// // handle a Band connection exception
// throw ex;
//}
}