segue code crashes after all tasks are done? - swift

I am doing this for an online class. The code seems to be the same as the instructor’s, which is working in their video. Yet, every time I run it, it updates the text field in the second view controller, then crashes. All this app is supposed to do is take an input in the text box on the first screen and display it in the label on the second screen after the user presses the “button” button.
Here’s the link to the entire file (it’s a very simple program).
https://drive.google.com/open?id=1Cn2OD18vdy7OoQ6bRWjK-Fq2MPaMVc1v

You have attached something and removed it from viewcontroller. That's why storyboard was looking for reference of it. You have to remove that reference from storyboard also, Please have a look in this screenshot. Remove warning sign variable and run your application.

Related

Can't move focus from table view to adjoining button on tvOS

I have a single ViewController which contains a Table View on the left and a few labels on the right. Navigating through the table view entries works fine (up/down). Focus is no problem there. Even the related text in the labels is updated just fine using tableView:didUpdateFocusInContext.
The interface looks like this:
However, the button on the right ("Jetzt ansehen") never gets focus. When I use the debugger (as suggested in the official documentation), it doesn't include the button in the focusable area at all:
I really tried to solve this using UIFocusGuide, but I have no real idea how to accomplish that, yet.

Why is this iPhone app's "quote" button not replacing the Text View's lorem ipsum?

I am working through the "iPhone introduction for programmers" tutorial at http://www.raywenderlich.com/21320/objectively-speaking-a-crash-course-in-objective-c-ios6, and my present project is at http://JonathansCorner.com/project/Quotes.tgz. The tutorial's focus is on providing an iPhone app that randomly displays one of several quotes in a Text View when you click on a Button. Later on the tutorial pushes further by defining properties and storing and retrieving XML, but I'm at the first "Let Her Rip!", which offers the first attempt running the app within the simulator with some increment of functionality, which should be that when you click a button, a randomly pulled quote appears. The text should be read-only as far as editing with the keyboard is concerned.
The behavior I am presently observing is that the simulator displays the Text View's native lorem ipsum. It continues to do so after clicking the button, and when you click on the Text View, it pulls up the keyboard and edits it. I've checked my wiring, and I don't see where I failed to duplicate what the tutorial shares. (The tutorial references a ViewController.[h|m]; is it a problem that I have a prefix before everything that takes a prefix when creating the project, e.g. CJSHViewController.h?) It behaves like one would expect from following the tutorial up to that point but not wiring event handling up or turning off edit mode for the Text View.
Any help or nitpicks would be welcome. (I am a programmer just beginning in iOS, so if there are "programmers new to iOS development" errors, I may have made at least one.)
Thank you,
The function you wrote for changing the text in the text view is working perfectly. The problem is with your IBOutlets. You never linked the outlet for the text view to the text view and consequently when you assign new text to it, it has no where to go.
Ok checked your project and found the error:
The problem is that quoteText is not referenced on the storyboard file so...
Go to your .storyboard file and drag the + symbol from the Connections Inspector to the view controller as shown on the screenshot when you click up a context menu should appear with the following options
quoteText
view
Of course you click on quoteText
Hope this helps

Splash screen getting invoked on map

I am working on a small project and my query is i have a view which displays the map and prompts me to use my current location.
my query is that when i press allow or dont allow button of the pop up it relaunches my app displaying my splash screen and then takes me back to my mapview.
So can we stop this from happening and does anyone know why this happens.
Thanks in advance.
As said in the comments, this "question" is hard to answer. Here's a try:
The popup is actually not shown by your app, but by iOS. Upon return of the popup, your application delegate's -applicationDidBecomeActive will get called. Apparently you (or the person who wrote the code for you) takes this as a sign to launch your splash screen. Of course, this should only happen when coming from the background or on startup.
So my guess is that the app is actually not relaunched at all. Put some logging in each of the application delegate functions, to see when and in what order they are called.

iOS Objective-C UIButton action not working correctly

I am making a simple application for iphone (for learning and education purposes). Inside the .XIB file there is a button used to clear all text fields on the screen. I create a "clear:" method for the button. assign the method to "Touch Up Inside", but when I run the app in iOS Simulator the button acts like the "clear:" method has been assigned to "Touch Up Outside". I click the button nothing happens, I click and hold the button then drag my mouse pointer outside of the button and let go and all text fields clear. Can anyone help me make it so "Touch Up Inside" works properly? (If I am completely mistaken, and sound like a noob just tell me, I am a beginner)
Are you sure you have it hooked up correctly to TouchUpInside? Try deleting that Send Event association, and redoing it.
It should look something like this:

Getting started with PopoverView and Display Item on Label in ipad

I am making a sample application where I am using UIPopoverView to display the list of items.
I am following this link for my sample application.
In the above link tutorial, a "movies list" appears. When the button is clicked, a pop over appears,but when I select the movie name it is not getting displayed on label.
can anyone tell what is happening or anything should be added in the code. I am not able to display the selected items on the label.
Check the connections of buttons and the respective actions. Debug the code placing the break point. I think u have missed something from the tutorial.
print the string whatever you are selecting .And print the label text also.Check whether you are getting the strings correctly or not.So that you came to know where the mistake is.