I want to take a screenshot of my iOS application when it is running in the simulator, and save the screenshot on my Mac. How can I do this?
Go to menu File->Save Screen Shot
or
Press ⌘+S
Screen shot saves in desktop
For some reason the commands posted before dont work for me, but this one does:
xcrun simctl io booted screenshot screenshot.png
Running Xcode 9.2
Simple answer with sample answer ;-)
on iOS Simulator,
Press Command + control + c or from menu : Edit>Copy Screen
open "Preview" app, Press Command + n or from menu : File> New from clipboard , then you can save Command + s
UnCheck Alpha
You can change Image dimension to your requirement.
Here is the Final Image,For example
First, run the app on simulator. Then, use command+s, or File -> Save Screenshot in Simulator to take necessary and appropriate shots. The screenshots will appear on your desktop by default.
Click on the camera icon above simulator to capture screenshot and save to your camera roll
Another option: File > Save Screen from simulator