VS 2017 crashes when opening iOS project's properties

SmeSme USMember ✭✭✭

I have a Xamarin.Forms solution, and when I try to view the properties of my iOS project (either by double clicking Properties, or right-clicking the project and selecting Properties), VS crashes.

Xamarin.iOS 10.8.0.174
Xamarin for VS 4.4.0.34

I'm not sure where to begin in terms of trying to solve this problem, so any help would be appreciated.

Posts

  • SmeSme USMember ✭✭✭

    Taking a look at the log file, I see this error from VS:

    System.UnauthorizedAccessException: Access to the path 'C:\Users\Me\Documents\Visual Studio 2017\Projects\MyProject\MyProject\MyProject.iOS\Entitlements.plist' is denied.
       at System.IO.__Error.WinIOError(Int32 errorCode, String maybeFullPath)
       at System.IO.FileStream.Init(String path, FileMode mode, FileAccess access, Int32 rights, Boolean useRights, FileShare share, Int32 bufferSize, FileOptions options, SECURITY_ATTRIBUTES secAttrs, String msgPath, Boolean bFromProxy, Boolean useLongPath, Boolean checkHost)
       at System.IO.FileStream..ctor(String path, FileMode mode, FileAccess access)
       at Xamarin.MacDev.PObject.Save(String filename, Boolean atomic, Boolean binary)
       at Xamarin.VisualStudio.IOS.Widgets.EntitlementsPanel.Save() in C:\d\lanes\4471\3f99c5a7\source\xamarinvs\src\Core\VisualStudio.IOS\Widgets\EntitlementsPanel.cs:line 377
       at Xamarin.VisualStudio.IOS.Widgets.EntitlementsPanel.EntitlementsChanged() in C:\d\lanes\4471\3f99c5a7\source\xamarinvs\src\Core\VisualStudio.IOS\Widgets\EntitlementsPanel.cs:line 198
       at Xamarin.VisualStudio.IOS.Widgets.EntitlementsPanel.cbEnableEntitlements_CheckedChanged(Object sender, EventArgs e) in C:\d\lanes\4471\3f99c5a7\source\xamarinvs\src\Core\VisualStudio.IOS\Widgets\EntitlementsPanel.cs:line 336
    Xamarin.VisualStudio.UnhandledExceptionsManager|Error|0|An unhandled error occurred. Details: Access to the path 'C:\Users\Me\Documents\Visual Studio 2017\Projects\MyProject\MyProject\MyProject.iOS\Entitlements.plist' is denied.
    
    System.UnauthorizedAccessException: Access to the path 'C:\Users\Me\Documents\Visual Studio 2017\Projects\MyProject\MyProject\MyProject.iOS\Entitlements.plist' is denied.
       at System.IO.__Error.WinIOError(Int32 errorCode, String maybeFullPath)
       at System.IO.FileStream.Init(String path, FileMode mode, FileAccess access, Int32 rights, Boolean useRights, FileShare share, Int32 bufferSize, FileOptions options, SECURITY_ATTRIBUTES secAttrs, String msgPath, Boolean bFromProxy, Boolean useLongPath, Boolean checkHost)
       at System.IO.FileStream..ctor(String path, FileMode mode, FileAccess access)
       at Xamarin.MacDev.PObject.Save(String filename, Boolean atomic, Boolean binary)
       at Xamarin.VisualStudio.IOS.Widgets.EntitlementsPanel.Save() in C:\d\lanes\4471\3f99c5a7\source\xamarinvs\src\Core\VisualStudio.IOS\Widgets\EntitlementsPanel.cs:line 377
       at Xamarin.VisualStudio.IOS.Widgets.EntitlementsPanel.EntitlementsChanged() in C:\d\lanes\4471\3f99c5a7\source\xamarinvs\src\Core\VisualStudio.IOS\Widgets\EntitlementsPanel.cs:line 198
       at Xamarin.VisualStudio.IOS.Widgets.EntitlementsPanel.OnEntitlementsPanelLoad(Object sender, EventArgs e) in C:\d\lanes\4471\3f99c5a7\source\xamarinvs\src\Core\VisualStudio.IOS\Widgets\EntitlementsPanel.cs:line 212
       at System.Windows.Forms.UserControl.OnLoad(EventArgs e)
       at System.Windows.Forms.UserControl.OnCreateControl()
       at System.Windows.Forms.Control.CreateControl(Boolean fIgnoreVisible)
       at System.Windows.Forms.Control.CreateControl(Boolean fIgnoreVisible)
       at System.Windows.Forms.Control.CreateControl(Boolean fIgnoreVisible)
       at System.Windows.Forms.Control.CreateControl()
       at System.Windows.Forms.Control.WmShowWindow(Message& m)
       at System.Windows.Forms.Control.WndProc(Message& m)
       at System.Windows.Forms.ScrollableControl.WndProc(Message& m)
       at System.Windows.Forms.ContainerControl.WndProc(Message& m)
       at System.Windows.Forms.UserControl.WndProc(Message& m)
       at System.Windows.Forms.Control.ControlNativeWindow.OnMessage(Message& m)
       at System.Windows.Forms.Control.ControlNativeWindow.WndProc(Message& m)
       at System.Windows.Forms.NativeWindow.DebuggableCallback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)
    

    Originally, this project was on another computer, but I transfered it to my current computer via thumbdrive; is this what could be causing the 'access denied' issue? If so, how to solve it? I have full read and write permissions to the file, and am an administrator on this machine.

  • SmeSme USMember ✭✭✭

    I solved this by connecting my project to TFS on my new machine, and then checking out Entitlements.plist. Nonetheless it would be nice to have an error message instead of a crash

  • olid4olid4 DEMember ✭✭

    Thank you very much @Sme , same error here with Visual Studio 2015.
    Occured after Xamarin for Visual Studio -Update to Version 4.4.0.34.
    Solved as described above, by checking out "Entitlements.plist"-file after a long and unnecessary search.

  • AshleyGazichAshleyGazich USMember, Xamarin Team Xamurai

    Bugzilla cross-reference

    Bug 54661

Sign In or Register to comment.