Change size of alertViewController - ios

I want to add switches and labels to my alertViewController, so i need to change the size of the alertViewController.
How can I do this (Objective C).
Thanks

Somebody posted an answer and then deleted it. As rmaddy says in his comments, you can't customize UIAlertController like that. You'll have to create your own custom alert controller class, or find a third party framework that offers the features that you want.
(When I've needed to customize an alert beyond what Apple's UIAlertController allows, I had good luck finding a 3rd party library that let me do what I needed to do.)

You can not change the size of the alert view controller. Make a custom view and add on it.

You will need to create a subclass of UIAlertController thats the only way you can modify something.
I recommend that you use a third party library SCLAlertView

Related

How to load another UIViewController to a UIView Example Like UITabbarController

I have a 2 UIViewController(s), I need to be able to change the views at the bottom of the Airtime and Data Plan Upon tap gesture on Airtime and Data Plan!
The yellow line will indicate the active view controller. some thing like tab bar.
Perhaps, the image attached is an android version
Could anyone provide a help on how to go about this.
Thanks
I personally use a library called ICVIewPager
https://github.com/iltercengiz/ICViewPager
This is pretty simple and easy to use with examples. It should put you in the right direction without writing a lot of code.

Component in iOS to make a selector option

I wonder which component is being used to create a selector option like the one used in iBooks where we can adjust the Font Size and also the Theme, but without moving to a new view controller.
In my application I would like to implement it giving 3 small options to the user to choose, but without moving the view controller being presented. Its a small square area with an arrow at the bottom or top side giving the impression where it's coming from. (Let me know if I am not clear with the explanation).
Does anybody know how to use it??
Thank you all in advance
ibooks is using UIView. In that UIView you can add any controls you like. You need to use delegate methods so that I can perform communication between two objects(send message to another object). You will be able to make you custom UIView as controls.

Implementing a "context menu" with a grid of buttons

I'm wondering whether there's a better way of implementing a "context menu" in my app. This is a screenshot of how it currently looks like and as you can see, almost the entire screen is already filled up with entries:
This is actually a UIAlertView with multiple "other" buttons.
I wondered if it's possible to create sort of a grid layout within the alert view and add three buttons per row which show icons only, instead of labels (in order to save some space). I'd like to make it similar to this (photoshopped) layout:
I read that it's possible to create a popup with custom stuff in it by using a UIView but perhaps you guys know an easier trick of accomplishing the same thing with an UIAlertView.
Is this even possible with an alert view?
it's impossible to create an UIAlertView like this.. Create a new UIView and add it to your viewController with [self.view addSubview:..]
You should use UIActionSheet instead of UIAlertView in this case. Or you can use modalViewController something like this: http://timneill.net/2010/09/modal-view-controller-example-part-1/

AlertView with Checkbox Control in iOS

I want to display an alert view dialog in ios with usual title, message and two buttons + additionally I need a check box with message like "Always show this". In apple HIG document, they stated better to use an action sheet or view controller instead of displaying more controls in an alertview. Any alternative options are there?
Thanks in advance
You can create Custom View in which you can you all the required control and if you want to show the you can also use nice animation to show them and also you can set some good graphics as well. So the best way is to create CustomView.
All the best !!!

How can a Popup like the "Select Wi-Fi Network" alert be implemented

In iOS, a popup is shown from time to time that asks the user to join a Wi-Fi network.
I want to implement a similar popup with custom contents
Title
TableView with a varying amount of entries (if too many, with scrollbar)
Cancel button
Popup over an existing view (the popup is smaller than the view)
How can such an effect be achieved? I guess that UIAlertView may be a good starting point. However, UIAlertView does not support subclassing
The UIAlertView class is intended to be used as-is and does not support subclassing. The view hierarchy for this class is private and must not be modified.
Not with the system UIAlertView. You have to code your own, or use an open source component.
This could be a starting point/example: BlockAlertsAnd-ActionSheets
Check this out, it is exactly the thing you need: github example project

Resources