Inheritance: RemObjects.SDK.AsyncProxy, IWindowsPhonePushProviderService_Async
コード例 #1
0
ファイル: MainPage.xaml.cs プロジェクト: remobjects/Push
 private void UnregisterOnServer()
 {
     var lService = new WindowsPhonePushProviderService_AsyncProxy(message, clientChannel);
     lService.BeginUnregisterDevice(deviceId.ToString(),
                                  ar =>
                                  {
                                      try
                                      {
                                          lService.EndUnregisterDevice(ar);
                                          Log("Device unsubscribed from notifications.\n");
                                      }
                                      catch (Exception ex)
                                      {
                                          Log("Exception during unsivscribing.\n{0}", ex.Message);
                                      }
                                  }, null);
 }
コード例 #2
0
ファイル: MainPage.xaml.cs プロジェクト: remobjects/Push
 private void RegisterOnServer(String notificationUri)
 {
     var lService = new WindowsPhonePushProviderService_AsyncProxy(message, clientChannel);
     lService.BeginRegisterDevice(deviceId.ToString(), notificationUri,
                                  Environment.OSVersion.Version.ToString(), "WinPhoneClient",
                                  ar =>
                                  {
                                      try
                                      {
                                          lService.EndRegisterDevice(ar);
                                          Log("Channel URI sent to server\n");
                                      }
                                      catch (Exception ex)
                                      {
                                          Log("Exception during URI update on the server:\n{0}", ex.Message);
                                      }
                                  }, null);
 }