ios-simulator

Invalid Device State - Xcode/iOS Simulator error

假装没事ソ 提交于 2019-11-26 16:38:45
问题 Problem: I cannot simulate an Apple watch interface. Whenever I try and test my Apple watch app on the iPhone 6 simulator, Xcode successfully finishes and builds the app, attempts at opening simulator and fails with an error message which reads 'Invalid Device State'. I believe simulator has a watch simulator that opens along with the compatible iPhone simulator models that can communicate with Apple watch (example: iPhone 6) Although I have yet to see it work. I have built a universal

wrong frame size in viewDidLoad [duplicate]

陌路散爱 提交于 2019-11-26 16:05:22
问题 This question already has answers here : Closed 6 years ago . Possible Duplicate: Why am I having to manually set my view’s frame in viewDidLoad? I have universal app for iphone and ipad, two storyboards, if I run my app on the iphone simulator in viewDidLoad every frame of each element in nib is correct. But if I do it for ipad (simulator) in frame is nil, but the screen looks correct. Could you please advise me smth? Thanks. 回答1: It's a very similar question to ios setContentOffset not

Failed to Attach to Process ID Xcode

 ̄綄美尐妖づ 提交于 2019-11-26 16:01:12
Anyone has experienced this problem? Yesterday I still can run my app in simulator but now I cannot run my app since Xcode prints this error in console: error: failed to attach to process ID <ID number> I have tried to reinstall, do this post and create new project but returns no luck. Anyone can resolve this issue? I use Xcode 4.5 Preview 2 and try to run iOS simulator 6 Resetting the content and settings in the simulator worked for me. This is available in the "iOS Simulator" menu. go to the Product menu and find the Edit Scheme menu there. While in Edit Scheme window, select the "Run"

How to resize the iPhone/iPad Simulator?

不羁岁月 提交于 2019-11-26 16:00:56
The iPad-simulator is really small (like one third the size of the real iPad screen) on my 23" Full-HD screen (and also on the 15" MacBook Pro ). Is there a way to resize it? I know it must maintain size and dpi-ratio to prevent sub-pixels, but I can hardly see anything withoout a magnifier. ⌘ + 1 for 100% ⌘ + 2 for 75% ⌘ + 3 for 50% Xcode 9.x : Select Simulator Goto Window tab Select Physical Size option ( cmd + 1 ) Now if this dosen’t make size as per your interest then follow below steps : Select Simulator Goto edge of simulator . This will convert your cursor to resize option

How do I add images to the iOS Simulator

随声附和 提交于 2019-11-26 15:58:31
问题 I have xcode 4.5.1 and want to add photos to the iphone 6.0 simulator but cant find it. I have a folder named iphone simulator but it just contains 4.3.1. It may be because some months ago I drag almost everything in the application support to my extern hard drive to save some memory. Now when I drag it back it contains the 4.3.1 which I used before. Do I have to download something on new or what should I do? Thanks in advance! 回答1: Run the simulator Run Safari on the Simulator Drag a picture

How to install iOS 7.0 and iOS 8.0 Simulators in Xcode 6.1?

空扰寡人 提交于 2019-11-26 15:58:07
问题 I want to test my app on both iOS 7.0 and iOS 8.0. I upgraded my iPhone5 to iOS 8.1. Now the only way to test my app in these OS' are using Simulator. But after upgrading my Xcode to 6.1. I'm unable to see iOS 7.0 and 8.0 Simulators. I need to install these simulators in Xcode 6.1. Is there any way to install these Simulators in Xcode 6.1? NOTE: 1) I copy pasted these simulator SDKs from old Xcode to the Xcode 6.1's contents but it didn't work. 2) I tried installing these from Xcode >

iphone - How do I add videos to iPad simulator?

不打扰是莪最后的温柔 提交于 2019-11-26 15:22:36
问题 No, dropping the videos to ~/Library/Application Support/iPhone Simulator/3.2/Media/DCIM/100APPLE does not work totally, because the simulator can see the video on Photos.app, but when I try to pick a video using UIImagePickerController my application crashes. I think this may have some relation to the format the video has to have. I am using QuickTime to generate the video. I am using the settings "for iPhone"... so it is generating a M4V with 480x360 pixels H264. I have tried to create a

Dial a phone number with an access code programmatically in iOS

℡╲_俬逩灬. 提交于 2019-11-26 15:12:41
问题 How can I dial a phone number that includes a number and access code programmatically in iOS? For example: number: 900-3440-567 Access Code: 65445 回答1: UIDevice *device = [UIDevice currentDevice]; if ([[device model] isEqualToString:@"iPhone"] ) { [[UIApplication sharedApplication] openURL:[NSURL URLWithString:[NSString stringWithFormat:@"tel:130-032-2837"]]]; } else { UIAlertView *notPermitted=[[UIAlertView alloc] initWithTitle:@"Alert" message:@"Your device doesn't support this feature."

iPhone Simulator suddenly started running very slow

自闭症网瘾萝莉.ら 提交于 2019-11-26 15:03:14
问题 I have been working on an app in iphone simulator for a number of weeks and it has been running well up until now, but all of a sudden has begun running very slow both when loading content and animations. I have not made any changes to my code since I last tested it successfully. I tried restarting the simulator (multiple times) and removing the app and doing a completely clean rebuild, but no luck. I also checked my cpu usage through the monitor while the simulator is running and I am only

Xcode Simulator: how to remove older unneeded devices?

我的梦境 提交于 2019-11-26 14:58:40
问题 I'm running Xcode 4.3.1 iOS-Simulator which originally only supports iOS 5.1. I need to test my code with iOS 4.3, so I used Xcode's "Install" feature to install it as described in "Installing Xcode with iOS 4.3 device simulator?" Now I'm finished with testing but cannot find a way to uninstall the 4.3 portions ("iPhone 4.3 Simulator" and "iPad 4.3 Simulator"). I want to reduce the clutter in the Scheme menu. No one on Apple's Xcode listserv knew the answer! EDIT: note that much has changed