iphone - Up/down arrows in nav bar of detail view to page through objects in parent table -


I have created an up / down arrow Segment control button on the right side of the navigation bar in the I table based application, How can I use these up / down arrows, which can be taken through cells in the feet table?

Apple "Navbar" is an example of sample code but the controls are not functional.

The iBird program also has this functionality and it is very good.

Thank you!

I had to work with some small problems. Here's my current code. It is not very beautiful It is working. SegmentActionPress is an NSInteger set .h file which I used to specify if the volume control was used to move in the next scene.

- (IBAction) Section Action: (ID) Sender {NSIndexPath * selectedRow = CurrentIndexPath; // Current indexpath is a nsidxpace object that holds the current indexpath. NSIndexPath * scrollIndexPath; Self.segmentActionPress = 1; Self.tableView.delegate = self; If ([sender selected segment index] == 0) {[self. Navigation controllerpwuControllerUnmitted: no]; If (selectedRow.row == 0) // If the top button is pressed, send us to the last line, on the first row. {ScrollIndexPath = [NSINXPath IndexPathForRo: Performance in Tabledesource.Contents1: Selected R.SECTION]; [Self.tableView selectRowIndexPath: [NSIndexPath indexPathForRow: tableDataSource.count -1 in the feature: selectedRow.section] Animated: No scrollPosition: UITableViewScrollPositionMiddle]; [Self Tableview: Self-Televisions did the selection of Endindappath: [NSINX XPath IndexPathoforro: TableDataSource: Display in signal-1: selected RO.sections]]; } If (selectedRow.row> gt; 0) // If there is on any other line when the top button is pressed, then go to the next line {SrollIndexPath = [NSIndexPath indexPaththorer: Selected ROOW.row-1 in the attribute: selectedRow. Section]; [Self.tableView selectRowIndexPath: [NSIndexPath indexPathForRow: keyword in scrollIndexPath.row] Animated: No scrollPosition: UITableViewScrollPositionMiddle]; [Self-tableview: Self-televisions had selected the endindependent path: [NSINX XPath IndexPathFor: ScrolledExpath.Orchance: Selected R.SECTION]]; }} And if ([sender selected SEgeIndex] == 1) {{self.navigationController popViewControllerAnimated: NO]; If (selectedRow.row == tableDataSource.count -1) // If pressed in the top row, then go to the first line {ScrollIndexPath = [NSIndexPath indexPathForRow: 0 in attribute: selectedRow.section]; [Select Self.tableViewRockoutPath: ScrolledExpath Animated: No Scrollposition: UITWebScrollPoMillied]; [Self Tableview: Self-Review was done by Selewview: Endpiece: ScrolledExpath]; } If (selectedRow.row & lt; tableDataSource.count -1) // If there is a line pressed on the other side, go to the next line below {ScrollIndexPath = [NSINXPath indexPathForRO: Expiration in selected ROOW.row + 1 : Selected RO.sections]; [Select Self.tableViewRockoutPath: ScrolledExpath Animated: No Scrollposition: UITWebScrollPoMillied]; [Self Tableview: Self-Review was done by Selewview: Endpiece: ScrolledExpath]; } In my diets - Diet SatoAppet method, I used the following code to go to the next scene without any animation if the up / down arrow is used.
  if (Segment Actionpress == 0) {[Self-Control Push ViewController: Animated TVC: Yes]; } And if (Segment Actionpress == 1) {[Self-Control Push ViewController: Animated TVC: No]; }  

Finally, I set the following code to set up the setting when pressed on "0" if the diploid view is visible. I unselect the line here so that you can see which row you picked when you were back on the original view.

  - (zero) visibleVIPE: animated {BOOL} {self.segmentActionPressed = 0; [Self.tableView Unselected RouteAppath: CurrentIndexpath Animated: Yes];}  

The main problem is that the segment buttons are never pressed and when the button is touched instead of the release, the action was sent immediately. As with "Touch up inside" action,


Comments

Popular posts from this blog

c# - ListView onScroll event -

PHP - get image from byte array -

Linux Terminal Problem with Non-Canonical Terminal I/O app -