iPhone Application Queries - iphone

Is there any way to achieve the following things via my application's code on the iPhone:
API for locking/unlocking the ios 5.0 device
Wipe the device data as in below app
http://www.engadget.com/2010/06/18/apple-launches-find-my-iphone-app/
Language change of the device
Device sound change etc

All of the activities you list here are handled by private methods, and as such, are off limits to App Store developers (and there is no official API to access them). That said, anything is possible if you're willing to forego distribution in the App Store and able to dig into the undocumented features of the native and/or jail broken OS.

Related

Auto-updated iOS application for enterprise distribution

Is it possible to make an iOS application for enterprise distribution that updates itself transparently? Saying 'updates' I mean completely updating its logic.
A possible usage of this approach is a self-service kiosk (iPad) that is maintained remotelly.
It's not possible to update application binaries directly, but I see some possibilities:
Application that have a single UIWebView and the logic is implemented in HTML5. But we can't use most of hardware specific features that can be used in native applications.
Some multi-platform framework (possibly HTML5-based) that allows to use native application features and that is compiled or interpreted dynamically.
Jailbreak?
What are really working approaches of these?
Consider getting a mobile device management service. Those are pricey.
OR:
First, enable over-the-air distribution. It will take $300/year enterprise agreement with Apple. Set up a website with the app's IPA archive and descriptive PLIST.
Then code a call-home HTTP request on app startup. You may pull/parse the same PLIST that describes the latest version; it has a bundle version in it. Compare that to the version of the currently running bundle.
When a new version is detected, the app shuts down, opens the browser on the download page. In a softer manner, just notifies the user that an upgrade is available.
I've never tried linking directly to the app's download package, but give it a try. In a perfect world, Safari would open up and ask "Do you want do download MyApp?" right away. In a not so perfect world, the user would have to click a link and then agree to download.
I think what you are looking for these days is the "Apple Deployment Program".
You volume purchase iPads which get sent to people, but that you can manage remotely - which also means management including remote updates of applications.
The only thing I'm not sure of is if you can launch an app remotely, so that you could update and re-launch an application.
Here's a guide to enrolling devices for remote management:
https://www.apple.com/business/docs/DEP_Guide.pdf
An old but good summary of the program:
http://www.speirs.org/blog/2014/2/27/understanding-apples-new-deployment-programs
Also watch the WWDC video on Managing Apple Devices for the Enterprise:
https://developer.apple.com/videos/wwdc/2015/?id=301

iPhone SDK Modify WiFi Settings

I need to be able to modify the WiFi settings on a iOS device (iPhone and iPad), most of the libraries are found so far via google search are private libs... Apple don't like this, does the SDK allow this in another way?
Thanks
Without jail breaking the device, you cannot modify the Wi-Fi settings. This is because all iOS applications are sandboxed, meaning they only have access to the data Apple allow deems necessary to the functioning of the app. For iOS apps, the documents directory constitutes the application's sandbox and the application cannot create or modify files or directories outside of these directories. So even if you found a way to modify Wi-Fi settings, your app would be rejected by Apple. Hope this helps!
Apple does not expose any public APIs that allow you to do this.

find iPhone places using xcode

I would like to know my iPhone places using Xcode like this app.I know all the details related to my iPhones.Kindly help me how to do this.
The actual Find My iPhone implementation details are certainly private and/or using private Apple frameworks (especially as it's a feature that users have to explicitly turn on and off via Settings and there's no user-facing app), but you could use CoreLocation in an app that you create that runs in the background, reporting your location to some server that your own.
I also found an alternative app named iLostMyi, but this requires a jailbroken phone.

Change iPhone settings from an app

Does anyone knows how to change the iPhone settings from interior of an app? For example: close the WiFi, disable 3G, change the sound volume and so on?
Apple is changing settings trough an app: Settings.app. It means that it's possible, I just don't know how.
Apple can do it in her Settings.app indeed.
Because of limitations of the iPhone SDK, some API's are not made public so you can't do everything Apple is able to do within her own OS. However, you can let the user adjust the main volume from your application, using the MPVolumeView class.
All applications written with the public SDK are sandboxed. They only have access to the properties and data which Apple deems feasible to use within that sandbox. Some of the examples you list are possible and some aren't.
Apple can perform these operations within their own applications since they don't use the public SDKs to write their applications - they use an internal SDK which has more functionality than the external one. They're not too worried about Apple employees hacking the phone and getting all your data off the phone.
Most of us wish that Apple could migrate more things to the public APIs (and they often do) but the reality is that the sandbox environment is carefully guarded. I wouldn't hold my breath to expect Apple to move all your examples over. You could always file a radar bug and let them know what you want - it's one way to have your voice heard.

Possible to generate an iPhone application automatically from another iPhone application?

As title; is there any function that can achieve this?
Officially, no. Official apps must be compiled and signed on an OS X machine.
In practice, sort of - if you don't mind jailbreaking. For jailbroken phones, gcc and signing tools are available that run on the iPhone. So on jailbroken phones you could have an application that generated new applications. Apple wouldn't let you sell such an app in the App Store, though.
Theoretically maybe, practically no. If you want to sell it in the App store double no.
I would take a look at this link which quotes the SDK in saying:
3.3.2. [..] No interpreted code may be downloaded and used in an Application
except for code that is interpreted
and run by Apple’s Published APIs and
built-in interpreter(s).
and
3.3.3 Without Apple’s prior written approval, an Application may not
provide, unlock or enable additional
features or functionality through
distribution mechanisms other than the
App Store.
between those two restrictions I think it would be practically impossible to dynamically create any kind of application on the fly (with the possible exception of the pure JavaScript/HTML app concept mentioned in the article).
If your iPhone is jailbroken, install "CallMe" from Cydia.
That does exactly what you want: It generates small applications with the icon of a contact, and if you launch one of those small apps, that'll launch the phone app and call the phone number of the contact.