How to open settings in single app mode on ipad - ios

I am building an app for iPad. For this I need to restrict user access on iPad and allow the user to only access my app and the iPad settings.
So I've tried 2 approaches:
Used guided access to lock down my app and from within my app had a button that launches settings. This button doesn’t work if I run in guided mode. Without guided mode it works and the settings open up.
Question really is – How do I allow my app and settings to work in
Guided mode?
The same scenario as above, when I use Apple configurator to launch only one app so all others are restricted. I need to allow both my app and the iPad Settings to work and no other apps.
How do I do this?

No you can't run more then one or multiple app in guided access mode. Because even if you want to press home button for going to background mode then also you need to end guided access. so, you can't open setting app from your app when guided access is enable for your app.
Only one app can run in guided access mode!
Refer apple doc, it states,
Temporarily restrict your iOS device to a single app
Disable areas of the screen that aren’t relevant to a task, or areas
where an accidental gesture might cause a distraction
Disable the hardware buttons

Related

IOS, awake app after unlock (entreprise app, supervised iPads)

I am currently prototyping an iOS iPad app for my company. Before I go in the details of what I am trying to do, this will be an enterprise app deployed by a local MDM. All the iPads that will have the app installed are supervised with a mobile config that allows the app to be in autonomous single app mode. So far, everything is working fine. The iPads are not (and cannot) be jailbroken.
I am looking for a way to basically switch the app to the foreground whenever the iPad is unlocked. I am aware of this thread (ios open app after screen unlock) from 2013, and I am hoping that 5 years later a solution has popped-up. Since our app is an enterprise app, it does not have to respect the app store requirements. I can successfully detect lock events if the app is opened when the device is locked, but when the app is not in the foreground, I would need it to be awaken from an iPad event.
The basic idea is that whenever the iPad would be unlocked, the app would freeze the iPad in single app mode, and the user need to perform some action inside the app to "reenable" the iPad and disable single app mode. If a user can re-lock the iPad and bypass the app (even if he successfully accessed it once) it's a no-go for us.
Edit
I am trying to awake the app after the unlock of the device. Basically once the iPads is unlocked (after pressing the home button) the app would be started automatically.
That is a loaded question but you could lock the ipad to only use one application with "Guided Access" There is a walkthrough here.
Here are the first steps:
Open “Settings”
Go to “General” > “Accessibility”
Tap on “Guided Access” (Scroll down the page a little, it’s under
the “Learning” section)
Flip the switch to “ON”
Tap on “Set Passcode” (this will prevent
users from leaving “Guided Access” mode)
Enter a passcode
Launch your App
With your app still open, triple-click the Home button

What is the proper UX for user to exit an iPhone app?

Is the iPhone "device Home button" (circle button that is part of the hardware at bottom center) the standard way that users exit an iPhone app?
I don't have an actual iPhone device yet (looking for the iPhone6 to come down in price a bit), am just working with Xcode simulators. When I run my iPhone Swift apps, they are always in full screen mode.
On Android, there are a few navigation buttons built into the OS that appear at the bottom of the screen - Back, Home, Open Apps. And in that OS you can give a directive to exit full screen to reveal those OS buttons.. which then allows the user to easily exit the app if they'd like to.
In looking at the iPhone apps on the simulator, I notice they don't have this kind of UX.
What are the best practices around iPhone users
A. Sending an app to the background ?
B. Quitting/Closing an app ?
To send an app to the background, hitting the home button is sufficient.
To quit an app, tapping the home button twice shows you all the open apps; you can then swipe an app to "kill" (terminate) it.
However, here is a recent post by the excellent John Gruber explaining why killing an app should only be a last resort: https://daringfireball.net/2017/07/you_should_not_force_quit_apps
Note: on the iPhone Simulator, the command-shift-H key combo is equivalent to hitting the home button.
To send an app to the background:
Press the Home button.
To "quit" or "close" an app:
Press the Home button.
That's all the UX expected of an iOS app... and none if it is actually provided by your app. iOS manages it for you; you just have to deal with your app's lifecycle methods to respond to the user leaving and re-entering your app.
iOS doesn't expect users to know or care about the difference between "background" and "closed/quit" in most cases. You enter an app, you leave an app, that's it.
And the way iOS works under the hood, there is no difference in most cases — when you leave an app, it's not "running in the background", it's "frozen" or "suspended": that is, in memory but not running. That way the OS can get it usable again near-instantly if the user comes back, or instantly reclaim that memory if another process needs it.
The user can also invoke the multitasking UI (double click home button, or in iOS 11 on iPad swipe up from bottom edge) and swipe an app away, but this is equivalent to the "kill" or "force quit" actions seen in other operating systems — it's primarily for situations where an app is misbehaving. This isn't part of your app's UX either; it's also provided by iOS.
As noted in the Daring Fireball post linked from #TimKokesh's answer, there are some circumstances where an app "in the background" isn't "frozen" but has some limited ability to run, the Settings app has UI to help the user keep tabs on what are using (and abusing) that ability, and those are some of the only cases where it's reasonable for a user to "force quit" apps.
If you want to have a real iPhone look-alike simulator on your development environment, yes it's available with New Xcode-9/Beta version. It shows real hardware buttons(volume, lock, home buttons) which you can press and feel like a real device. If you are interested you can download it from here
On other Xcode environments, you can go to home screen by pressing the keys: Cmd + Shift + H

How can i trigger my iphone application to launch from my mac app

I want to launch my app on the device (if App available) using the USB\Wifi\Bluetooth connection from my mac app.
How can I achieve this functionality
That is NOT possible. You can't do it using any public API. Though i am not aware of any private API that facilitate this types of functionality.
This is iPad control Mac's touch bar demo:
TouchBarDemoApp Allows you to use your macOS Touch Bar from an iPad (through USB connection) or on-screen by pressing the Fn-key.
Mac control iPhone:
iTunes Mac app can get the iPhone's screenshot and edit iPhone's apps.
Xcode can launch iPhone's apps when you debug ShareExtension.
So I think there are some methods to achieve your function. But I don't how to achieve. Maybe its private.
As already posted, you cannot directly launch an app.
But you can make your App show up on the lock screen as well as the task switcher so it can be opened with one click. This feature is called Handoff.
Here is the usage description for the end user and this is the programming guide on how to implement it.

canDisplayBannerAds and Airplane Mode

I'm testing my app in the Sandbox, and I'm using canDisplayBannerAds with iOS7. I had this working acceptably until I did some tests where I started the app in Airplane Mode (important to me because I need to detect if there is a network connection and if the user has paid to remove ads). With the iPad in Airplane Mode, I launch the app. Of course, no ads are displayed. Then, I switch to Settings (I don't explicitly quit the app), turn Airplane Mode off (the network is available again), but ads don't come back. Even if I set canDisplayBannerAds to YES again, it doesn't appear to help. The network is available, canDisplayBannerAds is YES, but no ads appear. Thoughts?
Ads won't appear in a number of circumstances, and I'm guessing this is one of them.
The real question you need to ask is
1.) How many users are going to find this out?
and
2.) Who has the time or effort to do this Airplane-mode-toggle-dance for your app. Apps are ephemeral experiences for the most part.

Is there a way to programmatically check if some specific mobileconfig has been activated?

This solution for an iOS kiosk mode (disabling the home button and on iPad the multitasking gesture) is really great, finally there is a possibility to implement a kiosk mode on iPads (even though it's quite complicated to activate and deactivate).
Lock-down iPhone/iPod/iPad so it can only run one app
I want to use this with a exam/quiz/e-assessement app. But how can my app check if this "kiosk" mode is actually active? Is there a way to programmatically check if some specific mobileconfig has been activated?
Use an MDM tool, like AppBlade. Here's a video on our kiosk mode functionality http://vimeo.com/50632312

Resources