Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 9311079
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 19, 20262026-06-19T01:16:28+00:00 2026-06-19T01:16:28+00:00

In my application on WP8 I work with all of the sensors. Accelerometer, Compass

  • 0

In my application on WP8 I work with all of the sensors. Accelerometer, Compass (from Windows.Devices.Sensors and from Microsoft.Devices.Sensors too) and Inclinometer.
Everything works fine until I push the Windows button and after that the Back button.
I get a full black screen with a “Resuming…” message and nothing happens. Once I got an exception (from 5 fauilure only once):

{System.Runtime.InteropServices.SEHException: External component has thrown an exception.
   at Microsoft.Devices.Sensors.SensorBase`1.PauseSensor()
   at Microsoft.Devices.Sensors.SensorBase`1.<>c__DisplayClass7.<.ctor>b__4(Object sender, NotificationCallbackEventArgs args)
   at Microsoft.Devices.Sensors.SensorCallback.MS.Internal.Interop.INotificationCallback.Pausing(XPauseType pauseType)
   at MS.Internal.Interop.NotificationService.NotificationPausing(XPauseType pauseType)
   at MS.Internal.FrameworkCallbacks.NotificationPausing(UInt32 pauseType)}

Did someone meet with this exception?

Or is there a best practice working correctly with sensors during the wp8 application lifecycle?

Thanks

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-19T01:16:29+00:00Added an answer on June 19, 2026 at 1:16 am

    This problem was more complex than I thought. I’ve worked a lot with this. I share what I found because I think my experiences with it could help later someone else too.

    I worked with the sensors through service classes: these classes update my VMs and in the VMs I use my DispatcherHelper to update these on the UI. I knew if I want to update UI bound properties in valuechanged events of the sensors I need to call this update in the eventhandler with a dispatcherhelper but what I did not know is how they behave if they are communicating with VMs instead of Views. When I started the app I had no problems with updating the UI if the sensors had new value. My only problem was in this case that if I wanted to deactivate (pressed windows button) and activate (pressed back button) my app, I had no exception, I did not lost my debug session but only got a black page with a „Resuming…” text and running progressbar and nothing happened.

    What I missed was a crossthread/accessing exception. If I do it with a UI bound data it throws an exception but in this case it did not.

    One other thing: the accelerometer (I had a version only working with the accelerometer) works with the emulator but on the device it does not. I think the emulator try to simulate the accelerator by giving back values, but not in a right way (without a threading issue).

    Solution

    If I update within an eventhandler on the UI thread (with my own DispatcherHelper) everything works fine. It is a good lesson learned, always pay attention when interacting with sensors and other layers/threads (VM,V).

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Application works fine. I can access everything in debug except for an Array Adapter
How to publish the windows 8 and WP8 application to windows store? I use
Application is sending email by using MFMailComposeViewController , everything works just fine. However after
In my WP8 application I would like to implement a functionality that is very
I have a C++ runtime component in a WP8 application, and if I change
I use C# and Visual Studio 2012 to develop a WP8 application. I added
Application I work on generates several hundreds of files (csv) in a 15 minutes
I'm trying to implant a contact chooser into my wp8 application but get the
In my WP8 application I have a UserControl with an active Storyboard animation that
I'm trying to convert my WP 7.1 application to WP8. The target is still

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.