Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.

Kapthehat

macrumors member
Original poster
Jul 1, 2013
51
0
I am working through the Big Nerd Ranch IOS Programming book page 107. I am looking at Chapter 5 -and trying to construct a graphical user interface. My XIB file has three objects (MKMapView, a UITextField and UIActivityIndicatorView. However, :-
1) I am missing a connection from the "LocationTitleField" to the "Text Field"
2) the connection view to view should be "view" to "text view"

Can somebody explain why I cannot make these connections. Much appreciated.

Thanks

Kaps
 

Attachments

  • Screen Shot 2013-07-05 at 15.02.08.png
    Screen Shot 2013-07-05 at 15.02.08.png
    448.4 KB · Views: 115
I am working through the Big Nerd Ranch IOS Programming book page 107. I am looking at Chapter 5 -and trying to construct a graphical user interface. My XIB file has three objects (MKMapView, a UITextField and UIActivityIndicatorView. However, :-
1) I am missing a connection from the "LocationTitleField" to the "Text Field"
2) the connection view to view should be "view" to "text view"

Can somebody explain why I cannot make these connections. Much appreciated.

Thanks

Kaps

It's not clear what you are trying to do. I think what you are saying is that you are trying to drag a connection from the "locationTitleField" on the left "Connection Inspector" onto the "Text view" entry in the hierarchical list of view objects in your XIB file.

Can you open that screen-shot in an image editor and draw circles around the two points you are trying to connect and then a line between them? (say in red at 2 pixel line thickness and 50% opacity)

If that's what you are trying to do, it would create an iBOutlet link from the "locationTitleFileld" outlet defined in your view controller's header to a text field in your XIB.

If I had to guess, I would guess that your "Text View" is a UITextView object, and the outlet is set up as a UITextField object.

UITextView and UITextField objects are not the same type of object, and you can't make a connection between objects of different types.

You need to switch one or the other object to the correct type.
 
Thank you Duncan - as you inferred, I have mixed up UITextView and UITextField. I will make these changes and then revise the connections. Much appreciated.

kind regards

Kaps
 
Thanks. now making more progress. I have all the correction connections except one - "view" to "view". Apparently this should be created by the template - but I can't see how !!!

regards

Kaps
 
Thanks. now making more progress. I have all the correction connections except one - "view" to "view". Apparently this should be created by the template - but I can't see how !!!

regards

Kaps

Remember when I got you to drag from the view to file owner in your last thread?
Do the same thing again :cool:

Control - Drag from the view of your app to the icon - file owner. When you let go it will pop up and show you "view" - click on it and this should sort out that connection.
 
Tander,

I thought it would be like that - but when I do as you've instructed, I dont get the relevant option pop up. Any thoughts ? thanks

Kaps
 
Tander,

I thought it would be like that - but when I do as you've instructed, I dont get the relevant option pop up. Any thoughts ? thanks

Kaps

Go to your connections and see if view shows it's connected?

It might already be connected.

What happens when you launch the app as is now?
Any compile errors?
 
Its not in the connections - I learnt the significance of that from last time.

No compile errors.

Nothing happens when I launch the simulator.
 
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.