Floating FB popout byF5debug

[Exception : Solution] - An exception of type 'System.UnauthorizedAccessException' occurred in System.Device.ni.dll but was not handled in user code


We might end up with the above exception while developing your window phone application development, basically on the location services enabled application development. To resolve this issue you need to follow the below steps, the exception is because of the application settings on the capabilities. This issue might be common across different other capability as well, so you need to activate the capability which we are planning to use it in our application development.     [more]


An exception of type 'System.UnauthorizedAccessException' occurred in System.Device.ni.dll but was not handled in user code




Open Visual Studio 2012 IDE and navigate to the project where the issue exists, now open the WMAppManifest.xml file under the properties section.


Go to the Capabilities section and select the appropriate capability, in our case we need to select ID_CAP_LOCATION from the list of available capabilities.


Save the project and build and execute the application to run in the emulator which will solve the issue. Hope this tip will be helpful for you and can be used in other capability fix as well.

About Author: Karthikeyan Anbarasan, Microsoft MVP (Most Valuable Professional) in ASP.NET/IIS Architecture. He is the Founder and Chief Editor of the www.f5debug.net website and has authored books on Windows Phone and Business Intelligence(SSIS). He is also a Passionate Speaker and a Blogger on Microsoft Technologies.

You can Join Me On: Facebook, Twitter, Google Plus, LinkedIn

Pingbacks and trackbacks (1)+

Add comment

  Country flag

  • Comment
  • Preview

Recent Posts

Random Posts

Most Viewed


Total posts: 4This year: 0This month: 0This week: 0Comments: 0

Month List

URL Shortner

Create your own short urls!!!

Site Counter

free counters


This is a personal weblog. The opinions expressed here represent my own and not those of my employer. For accuracy and official reference refer to MSDN/ TechNet. I have documented my personal experience on this blog.

Protected by Copyscape Web Plagiarism Finder

Site Meter