Questions tagged [viewcontroller]

viewcontroller is a design pattern which is a hybrid of the view and controller components of the MVC architecture

A viewcontroller responds to events by dispatching calls to a mapping table which matches views and controllers with each event target. It is implemented as an object in many frameworks, including:

2792 questions
0
votes
2 answers

How to add one common floating action button to all the UIViewControllers

I want to add the same floating action button in all my View controllers.I have a chat option(which opens up on clicking this button) and that should be accessible from all the pages of the app.How can I do the same.Instead of adding in redundantly…
Bryan
  • 15
  • 1
  • 7
0
votes
2 answers

iOS Swift 4: ist it more efficient to dismiss or present a ViewController

In an iOS app, to move between screens, I can either present a new ViewController ("move forward") or dismiss a current ViewController ("move backward"). In my naive understanding, this is simply a way of moving back and forth in the stack of…
AJGronevelt
  • 551
  • 1
  • 6
  • 22
0
votes
1 answer

Redirect to another StoryBoard from Notification?

By default from notification we open the first ViewController of the Mail.Storyboard. Is it possible to open another Storyboard? I tried few solutions already but don't works for me. Whole code is below. Let me know please if need more information.…
Roger
  • 3
  • 2
0
votes
4 answers

Crash when trying to push view controller in Swift

I am having a weird issue where my app crashes when I am trying to push a new view controller. I have set up a swipe gesture and want to segue to another view controller when a swipe is detected. When I run these 2 lines of code ... let…
coder
  • 381
  • 2
  • 22
0
votes
1 answer

Request for Member 'View' in something not a structure or union

I'm getting the error mentioned in the title. Here's my interface: #import @class ControllerLevel1; @interface RootController : UIViewController { ControllerLevel1 *controllerLevel1; } @property (retain, nonatomic)…
Trevor McKendrick
  • 595
  • 2
  • 7
  • 27
0
votes
2 answers

Change From a UIView to a UITableView

im a begginer Objective-c programmer and i stuck at this point. I Created an App from the View Template, then edited the view xib and add a button and assigned it to the showEdicoes function, but when i click it, it does execute the function(i…
Lordareon
  • 1
  • 1
0
votes
0 answers

Swift - Getting TableViewControllers to talk to one another

I'm working on an app which is date based. I'm trying to get information to pass from one TableViewController to another. It's a notification based app that reminds the user that something comes out today. So on the date it comes out, I'd like it to…
sckring
  • 31
  • 5
0
votes
2 answers

Select a single cell in a UITableView to go to a UITableView to display different student lists data

Updated I want to select each row to go to ViewController that has a TableView to display different student lists data, but for my code, it will display the same list as I created a new student object, How do I fix this? The problem is I don't have…
Neung Chung
  • 159
  • 1
  • 1
  • 10
0
votes
1 answer

Why doesn't code in (isMovingToParentViewController) run in viewDidLayoutSubviews()

I have a viewController, I'm using anchors and I want to get the frame of a button. I only want the frame when the view is pushed on so I use isMovingToParentViewController. Like this: if isMovingToParentViewController { let myButtonFrame =…
Lance Samaria
  • 17,576
  • 18
  • 108
  • 256
0
votes
1 answer

iOS -How to to locate ChildVC in NavigationController Stack after Parent Pushes On AnotherVC

I have a tabBar with a tab that contains a NavVC that has a root as a ParentVC. The ParentVC has a segmentedControl that manages two childVCs, RedVC and BlueVC. Both the RedVC and BlueVC contain a button to push on a YellowVC. The issue is when the…
Lance Samaria
  • 17,576
  • 18
  • 108
  • 256
0
votes
1 answer

App crashes when code is connected to storyboard

I've been trying to connect the IBOutlet's to the releasedatepicker, artisttextfield, albumtextfield, saveTapped and cancelTapped in my EditFreshReleaseViewController for a few days now. But whenever I run the app and tap the Edit button, it crashes…
sckring
  • 31
  • 5
0
votes
1 answer

View Controller not instantiating inside IF statement

I am designing an app where when the user first opens it AND they are currently logged in, I want it to take a snapshot of their data and then instantiate a view controller based on the criteria. In my example, if the user is a "driver" meaning the…
0
votes
1 answer

Passing Information from ViewController to ViewController using Swift

I'm new to coding and Swift. For my first attempt at an app, I'm attempting to make a mobile music reminder application, in which I can type in the Artist, Album and Release Date and it'll notify me on the release date that the album came out today.…
sckring
  • 31
  • 5
0
votes
0 answers

Why does Tab Bar Controller turn ViewController into View?

I am creating a simple iOS app. I started with a Tab Bar Controller. I added a UIViewController. I control click linked the Tab Bar Controller to the new ViewController (and picked segue: view controller.) From what I can tell, this turned my…
Paul K.
  • 95
  • 1
  • 12
0
votes
1 answer

iOS - Views (ViewController), having persistent data

I am currently working on an app using Xcode/swift 4 where I need a view (lets call it loggerView), which is not the main view, to be able to take data from the main view (or other views) in a manner that allows said data to be shown whenever…
Matt74
  • 31
  • 1
  • 4