system("killall SpringBoard"); not working in ios4.2.1? - iphone

So I had created an app that used the command system("killall SpringBoard"); and it has worked just fine on 4.0 - 4.1. I just recently began testing the app on 4.2 and it still works when I run it in simulator, but when I run it on the device nothing happens. Does anyone know what the cause of this is? The device is a iPhone 3GS.

If you want to restart SpringBoard cleanly, please use
notify_post("com.apple.language.changed");

Related

iOS Background Task in IOS 13 Not working

Im trying to work on with iOS 13 background tasks to be executed and created the sample application as per apple says:
https://developer.apple.com/documentation/backgroundtasks/bgtaskscheduler
But some how im still getting error in console as:
Can't end BackgroundTask: no background task exists with identifier 1 (0x1), or it may have already been ended. Break in UIApplicationEndBackgroundTaskError() to debug.
And this seems like many are experiencing this issue:
https://forums.developer.apple.com/thread/121990
Thanks
The BGTasks worked fine with the new iOS 13.4 and i tried this on real device and it seemed working fine.
So the issue was it wasnt working on simulator but on device its fine.
I never tried this on other device, rather i just tried on device with iOS 13.4. Seems to be fine.

Xcode 4.2.1: universal app runs on iPad but not on iPhone

I am working on a universal application where I am stuck at one point. I was able to successfully launch my application both on iPhone and iPad but since 2-3 days, I am not able to launch my application on neither iPhone nor iPhone simulator but it runs smoothly on iPad/iPad simulator.
Also when I run my app choosing iPhone device it shows message like Running the App on iPhone simulator but I am not able to see any effect on my simulator. I am using Xcode 4.2.1 and I guess the issue is pertains to the same.
I don't know whether it is a solution or not but got a way out by reinstalling the iOS Simulator.
I have faced same problem. This probably happens when you replace the application with the newScheme/EditScheme by mistake.
Just carefully check when you run your application is there your application name appear. This will be immediate left at where you choose iPhone simulator or iPad simulator version.

Xcode 4.1 - location prompt in iPhone simulator

The app I'm working on uses CLLocationManager, and previously, when the app starts asking for location info in the iPhone simulator, I would get a little popup.
Yesterday I installed Xcode 4.1, and now I no longer get the prompt. My app also never gets any location information, and times out every time.
Anyone know what I should check or where to start figuring this out?
You're not alone, seems to be a problem with the iPhone Simulator in Lion & Xcode 4.1, https://devforums.apple.com/message/491549

Xcode - No provisioned iOS device is connected

I was using Xcode this afternoon and debugging an app on my device just fine. When I got home from the office and plugged in my phone to keep working, XCode would no longer let me debug on my device. The error I received was:
Error Starting Executable. No provisioned iOS device is connected.
So I hopped over to the Organizer, and here is what I saw:
So what gives? Anyone seen this before?
Thanks!
Well I don't know why this helped, but if anyone else sees this thread the thing that "fixed" the problem was to remove the SDK from my machine, restart XCode, then plug in the device. XCode then popped up an alert view asking to collect the debugging symbols from the device, which I allowed it to do. From then on it worked like a charm.
You may be testing your application on simulator and accidentally, device is selected instead of simulator. It help me to sort out this problem.
Make sure you have upgraded to the latest Xcode 3.2.5 with iOSK 4.2.1 SDK.
I had another way of fixing this problem.
I tried upgrading my device to iOS5 Beta 7 ...to test my app in iOS5
Once i finished testing it, wanted to get back to iOS4.3.5 on my device...
it took a little pain but managed to restore it back to the original
but then the debugging didn't work and got the same error as mentioned here.
So i wanted to see what i see in that snapshot that you have : and there it was...
A button called "enable for debugging" if i'm not mistaken.
Worked like a charm.... :)

My app reboots iPhone on 4.1 iOS

I've upgraded my iOS on iPhone 3G to 4.1 and now I run my app on the device.
Firstly, I couldn't install it becouse Xcode was saying I don't have certification etc. (I have jailbroken iPhone). Finally, I succeeded and installed it.
But know something strange happens....
After I had installed my app on the device I run it.
Then, "cocos2d" image appears on the screen and just a second later device switch off! It simply reboots.
What's more - when the device launchs again and I run my app - it works!
I have no idea what's going on. This app works fine on 3.1.3 iOS (even with the same Xcode - 3.2.5)
What should I do?
Do you think the problem is caused by Xcode or iPhone itself?
Maybe reinstalling Xcode may help?
It could be one of two problems.
It could be a problem with your device. Maybe something got sort of wonky with your jailbreak.
Secondly, it could be a problem with your app. Maybe it's crashing. Have you checked your crash logs?