in iPad tableview shows more records when navgigate back from another view inside a popover
I have a popover view which displays a table with two rows and the size of the popover is adjusted to show only those two rows. After i click any one of the rows i navigate forward to a new table view and the popover size increases accordingly. when i navigate back to the original table view having two rows the popover size increases by one row. It shows a three rows with a empty third row.
Please find my code below.
in initWithFrame for the table view i set the value for popover using contentsizeforviewinPopover. works fine when the view loads
After navi开发者_JAVA技巧gating back i am setting the same value(contentsizeforviewinPopover) inside viewwillAppear. But now the view has three rows.
Please suggest any solution.
I got it rectified. When the initial table view navigatesforward to the next table view i will set the value for contentsizeforviewinPopover to zero in viewdiddisappear. Again when in navigate back, the popover displays with proper size with the proper values present in viewwillappear.
I think there is some problem with you table datasource. As you said that popover size get changed and also there is an empty row in the table. I think your datasource get updated with blank data.
Please check your datasource in between your navigation.
Thanks
精彩评论