Custom UIView in UITableViewCell - uiview

One of the UITableViewCells in my table contains a UIView which is like a 5-star ratings. However, the view cannot be selected.
The tutorial I'm basing it on is the following from Ray Wenderlich:
http://www.raywenderlich.com/1768/how-to-make-a-custom-uiview-a-5-star-rating-view
Any ideas?

Is User Interaction Enabled checked for the rating view in your storyboard file? In the Utilities right-hand sidebar of the storyboard editor, under the "Attributes" inspector's "View" section, you should find the "User Interaction Enabled" checkbox. (A similar checkbox also appears in the "Identity" inspector, see here for details.)

Related

How to place textfield in table view controller to read contents

I am a little stuck after reading a tutorial and trying to go it alone.
Essentially I am trying to link my form components (the text boxes and buttons) to my view controller window via control click and drop. In the book this looks fairly simple as its just a case of drag and drop but when I do it, nothing happens!
Please could someone give me some indication as to why this could be?
Please change the class of the UITableViewController in your storyboard to LoginTableViewController. Select the tableViewController in the storyboard and check the class inspector in Xcodes sidebar.You can change there to LoginTableViewController.

How to use Refresh Control in UITableViewController ios7

I am parsing an xml file and displaying it's content in a UITableView, I want to set up the pull to refresh feature. I noticed in the "attributes inspector" there is a section that says "Refreshing", I set that to Enabled. How do I actually set up the action to reload the data in the table? Thanks in advance.
You can implements the pull to refresh feature programmatically via coding or by doing drag drops from the Storyboard. This is the example on how to do it in the easy way (using drag drops).
Check the refreshing attribute on inspector
Then take a look at the storyboard, there will be new view named Refresh Control created underneath the TableView. Do right click on the view then implements the Value Changed event.
Please see image below.

how do I set up a table view in interface builder for a 'settings' type interface

So I guess the table view has been designed around the idea of using dynamic data received at run time, but I want to make a settings type app where all of the cell values are known as I build it, so I was hoping to be able to set the section / row configuration, labels ect, as well as the properties for each cell (whether it has other views inside it like a switch, or whether it is a button etc) all in interface builder.
can I do that? how?
I am using xcode 4.4.1
To use static cell content you have to make sure that you are adding a UITableViewController not just a UITableView dragged into a UIViewController. The latter requires dynamic prototypes.
Once you've added the table view controller to your storyboard it is as simple as selecting "static cells" in the attributes inspector. From there you can drag and drop UITableViewCells and modify them as you wish.

How to set UITableViewCell Identifier in Xcode 4

In Xcode 4, I failed to find where to set UITableViewCell's Identifier, can anybody helps me?
Thank you very much.
In code:
myTableViewCell.reuseIdentifier = #"CustomIdentifier";
In the interface design document (right-click and view image to get a bigger picture):
Go to the leftmost tab here, the Project navigator.
Select the .xib file containing your cell design.
Select the UITableViewCell object within the .xib
Make sure the rightmost "View" is showing and then go to the 4th-from-left tab, the Attributes inspector.
The top box labelled "Identifier" is where you enter your identifier.
When you create a new UITableViewCell in an interface document, select it, show Utilities by pressing Cmd+Opt+0. Under the "Attributes" inspector the first object is your identifier.
You can use the attribute named 'tag', type of NSInteger

Why does Interface Builder not show me class-specific attributes?

I am trying to implement Tim Keating's answer from here: Loading a Reusable UITableViewCell from a Nib
I made a view XIB and assigned the view's Class to UITableViewCell.
When I go to the Attributes Inspector though, all I see are the "Simulated User Interface Elements" and "View" sections. I do not see a "Table View Cell" section like in his answer :( I tried closing and reloading, it still won't show.
You can always select an empty XIB and pick a UITableViewCell element from the object library.

Resources