How to run Xcode 6.2 simulator? - xcode

At the top next to the play/run button, I only have an option for "iOS Device". The simulator is not an option. How do I run projects in the simulator?

You can manually start the simulator from the task bar. I think its under File -> Developer Tools -> iOS Simulator.
Also make sure your deployment target is set to the simulator's firmware.
If still you can't use the simulator you can tap on iOS Device and then add scheme. There you will be able to add simulators, even though this should have been there by default.

Related

How do I run an iPad Simulator in Xcode?

I am trying to run an iPad simulator on Xcode, but currently I only have one option when I go to Xcode > Open Developer Tool > Simulator, which launches the iPhone simulator.
How do I launch the iPad simulator?
You should select an iPad device by navigating to
Hardware/Device/[OS version if you have multiple OS versions installed]/[device]
in the simulator's menu.
If there are no iPad devices in the list, follow these instructions:
Click on Hardware/Device/Manage Devices...
Select the Simulators option on the top.
Press the plus (+) sign in the lower-left corner.
Define the name, the device type and the OS version of the new simulator, then click on Create.
For more information, check out Getting started in Simulator.
This is for Xcode 11.2.1+
open XCode, from the App menu:
Xcode -> Open Developer Tool -> Simulator
This will open the latest iPhone simulator and to change it to anything else e.g iPad:
Hardware -> Device -> iOS -> iPad
This has changed.
Now, after you opened your simulator as you mentioned you need in the simulator menu bar to go to:
File -> Open Simulator -> [ios version] -> [ios device]
There you can find an ipad simulator to open.
For bonus points :)
I would also extract the simulator from inside Xcode to make it more accessible.
Applications / Xcode.app ( right click and select "Show Package Contents" )
From this folder Contents / Developer / Applications / Simulator.app
Create a shortcut to that and simulator opens without opening the main Xcode.app
Open Simulator, go to File > Open Simulator > {Your version of IOS} > {Device you want}.
Dont Forget to rebuild your app before trying to launch it.

Xcode cannot run on simulator

in Xcode, I can see the simulators (in Window->Devices), however XCode itself will not recognize the simulator as an option to run on. Any ideas?
there may be two reason by which your Xcode not recognise simulator.
1.You have selected higher or lower version in development target.
Go to Xcode ---> window ---> Devices --> Add device on click + icon. it will be added a device on your Xcode .
Thanks
Enjoy coding.....

Can I set the default simulator for new projects in Xcode 7.1 or latest?

I've been making a ton of new projects as I'm learning Swift. My development is all on my laptop, so I hate using the default 6s Plus simulator, since the window is too big to easily see. Is there a way to change the default simulator to be a different one for new projects?
No need to delete simulators!
Product → Destination → Add Additional Simulators...
In the sidebar, select the simulator you want to hide
Uncheck "Show as run destination"
Edit: Updated for Xcode 10
You can select the desired simulator via the Hardware > Device > [OS] menu (Xcode 9):
While unchecking "Show as run destination" hides the simulator, this will also change the default value.
Updated image for Xcode 11.5
Xcode 9 UPDATE:
In Xcode 9, no need to delete simulators, and the way to turn them on/off is to go in Product/Destination/Add Additional Simulators... select the simulator you want to turn off, then uncheck the box: 'Show as run destination'
No. But...
If you don't like the size of the 6s plus simulator, make it smaller with the simulator Window Scale menu.
If you don't like the 6s plus simulator at all, delete it with the Xcode Window Devices menu.
Xcode 12.5
In Xcode, go to Product -> Destination -> Choose Destination menu and selecting the device you'd like to be your default.
The original answer could be found in apple support forum here: Apple support forum,
In addition if you want to make the device smaller just hover over bottom right corner of the simulator and you will see the resize option
Deleting the simulators you don't want will default you to the simulator you do want. I also develop on my laptop and the biggest simulator I can see w/o scaling down is the 4S, so I deleted simulators for iPhone 5 and above and now every project I create defaults to 4S simulator. If I ever need the newer simulators, I will just re-download.
In my case, just select the device in Product → Destination, Xcode 12.4
Xcode version 11.5
On Simulator > File > Open Device > iOS 13.5 > Change the default Simulator
Xcode(v11.5)
open your simulator, choose **File/Open Device/iOS 13.5/iPhone8 ** will change your simulator device to iPhone 8.
When you reopen your simulator, iPhone 8 will be your device simulator.

Why simulator getting crash on Device change from simulator in Xcode 5?

When i run simulator in my xcode 5 and later on if i try to change simulator Device from under menu 'hardware' of simulator it getting crash. which is something unlikely to xcode previous versions. Is it my xcode copy specific bug or something else?
I had the same problem. Instead of changing the device in the iOS simulator, change to the device of your preference in XCode. Notice your project name in the top left hand corner next to build and run button and stop button. To the right of that is a drop down for different device names. Pick the one that you'd like to simulate. Then build and run in iOS simulator.

App doesn't build on my device

The app I am working on runs perfectly in the simulator, on an iPad, and on an iPhone. When I try to run it on my iPod Touch, NOTHING HAPPENS...
Xcode says "Building..."
and then it says "Finished running"
Nothing is written to the console and the app icon isn't installed on the iPod Touch and the app never even attempts to run.
Any ideas what could possibly be going wrong would be greatly appreciated. If there was some error that came up that would at least be helpful, but nothing happens whatsoever.
Thanks so much!
EDIT: I've gone back and opened some of my previously finished apps and all of them do this same thing when I try to run them on the iPod Touch...
Could this have anything to do with my having upgraded to XCode 4.2 and the iPod Touch still running OS 3.1.3? The deployment target in Build Settings is still 3.1.3 and up, so I don't think it should be an issue...
Does your scheme target dropdown list show "iOS Device" or does it show the "name" of your iPod Touch (something like "jons ipod touch"):
If it shows "iOS Device", that means your iPod isnt recognized by xcode and you may need to enable the device for developing by clicking "Use For Development" like so:
The armv6 architecture needed to be added to the build settings in order for me to build to the iPod Touch (OS 3.1.3).
In Xcode 4.2, in the Build Settings, under Architectures, armv6 wasn't an option for me in the dropdown menu. I had to select "Other...", then use the + sign to manually type in "armv6" NOT IN PLACE OF but IN ADDITION TO what was already entered there, which was "$(ARCHS_STANDARD_32_BIT)" and then I was able to build my app to the iPod Touch.
As a final note - while I got the app to run on my iPod Touch OS 3.1.3, it did not run as well as I wanted it to (as well as it runs on the iPad OS 5 and iPhone OS 4.2) so while I've previously always supported OS 3.1 in my apps, I sadly ended up NOT supporting armv6 for this one and setting the iOS Deployment Target for my app to iOS 3.2

Resources