Xcode cannot run using the selected device

前端 未结 10 1246
刺人心
刺人心 2021-01-04 11:51

I am receiving the following error when I try to run my Xcode iOS project:

Xcode cannot run using the selected device. Choose a destination with a supported          


        
相关标签:
10条回答
  • 2021-01-04 12:23
    • Clean up your project using Clean, Clean folders, Delete derived data.
    • Delete all schemes from 'manage schemes'. Recreate them, and build using any of them that contains a version of iPhone simulator (the one that worked earlier).

    If that doesn't work, try this:

    • Clean up your project using Clean, Clean folders, Delete derived data.
    • Using your favourite editor, try clearing all the profile strings from your project.pbxproj file (the one that you see when you open your xcode project using 'Show Package Contents' command).

    See below image - you must delete all lines containing 'Provisioning Profile' till the ; character.

    • Then restart xcode. Select the profile using automatic profile selector and build using an iphone simulator scheme.

    enter image description here

    0 讨论(0)
  • 2021-01-04 12:28

    In XCode 6 I opened the Devices window (Window/Devices) and noticed my iPhone was not listed there, even though it was plugged in to the mac at that time. I unplugged it and then plugged it right back in while the Devices window was open, and it appeared in the device list and also in the scheme picker.

    0 讨论(0)
  • 2021-01-04 12:29

    I had this error when trying to run a DEBUG build. I changed "Build Active Architecture" to YES for DEBUG and this error finally went away after hours of frustration. I tried about 10 different things that I read on this site and nothing else worked.

    0 讨论(0)
  • 2021-01-04 12:32

    Check that the Executable File (also known as CFBundleExecutable) in the Info.plist file is set to ${EXECUTABLE_NAME} as opposed to any hardcoded value. This will ensure that even if you change your project name or target name or scheme name, that it still works.

    0 讨论(0)
  • 2021-01-04 12:34

    I had the same problem, and fixed it by opening the info.plist file in Resources and unchecked the target membership so that nothing is checked as target membership.

    0 讨论(0)
  • 2021-01-04 12:36

    Please Check the following: -Connect your device with another cable. -Check if the cable is properly connected. This was my problem Thanks

    0 讨论(0)
提交回复
热议问题