1

I have an issue where I am trying to use my iPod touch in to debug my .NET MAUI code. I plug my iPod into my Macbook and under Debug (where I set the devices) I get that my device OS version is lower than my deployment target. My iPod is version 15.7 and I'm using Xcode 14.2 for my .NET MAUI project:

enter image description here

The project is a new "HelloWorld" .NET 7 MAUI project.

I then open up my Project properties and under target platforms->iOS targets I change the Target iOS version from 16.1 to 15.4:

enter image description here

I can build and run for MacCatalyst but when I try to build and run for any of my iOS simulators (running iOS 16.2) my app crashed:

InnerException:

    InnerException  {System.MissingFieldException: Field not found: Microsoft.Maui.IPropertyMapper`2<Microsoft.Maui.IShapeView, Microsoft.Maui.Handlers.IShapeViewHandler> Microsoft.Maui.Handlers.ShapeViewHandler.Mapper Due to: Could not find field in class}   System.MissingFieldException

with Message:

"The type initializer for 'Microsoft.Maui.Controls.Shapes.Shape' threw an exception."   string

enter image description here

and the debug section still says my device OS version is lower than deployment target.

If I create a new HelloWorld project using .NET 6 instead of 7 I can change the deployment target for iOS to 15.4 and my project builds and runs on my iOS simulator (running iOS version 16.2) without crashing but I can't use my iPod for debugging (greyed out) as the iPod shows up as unsupported device as shown in image above .

Why can't I use my iPod touch running iOS 15.73 even after reducing the target iOS version to 15.4? (Also a bonus help would be why is my iphone simulator crashing for .Net 7 MAUI project)

Can someone help me figure this out?

Thanks!!!

ToolmakerSteve
  • 18,547
  • 14
  • 94
  • 196
David Pugh
  • 758
  • 3
  • 12
  • 33
  • Run Xcode. Is iPod touch found? If so, use Xcode to download device provisioning. Restart VS, reconnect iPod. Hopefully will recognize it now. – ToolmakerSteve Feb 13 '23 at 01:41

0 Answers0