logo
Tags down

shadow

Table View Height restricted Scroll


By : rahamathali
Date : October 16 2020, 08:10 AM
With these it helps so I have a table view which is the right size of my screen but the height is wrong because I cann't scroll down to see more parts/cells.
code :
tableView.frame = CGRect(x: 0, y: 75, width: self.view.frame.width, height: self.view.frame.height - 75)


Share : facebook icon twitter icon

Scroll table view to bottom when using dynamic cell height


By : WAOUMA
Date : March 29 2020, 07:55 AM
hope this fix your issue Eventually, I have found the answer. The reason why scrolling to the bottom does not work (and inserting/deleting rows are buggy as well, as I found out later), is because cell height is not properly estimated. To get around this, try to return close estimations in estimatedHeightForRowAtIndexPath:(NSIndexPath *)indexPath. However, if you can't do that (and in most cases you won't be able to) there is still a great solution: Store the heights of the cells in a dictionary, and return those for the estimatedHeight when cells are reused (e.g. table view is scrolled). I have found this solution in another question, so please go and check that out for the actual code on how you would carry this out. (although probably, many of you can write this for themselves)
Original solution by @dosdos
code :
let lastItem = IndexPath(item: dataSource.count - 1, section: 0)
tableView.scrollToRow(at: lastItem, at: .bottom, animated: true)

Change UIView In Scroll View While / Update Scroll View Height - Swift 3 / Xcode 8


By : user206
Date : March 29 2020, 07:55 AM
To fix the issue you can do I have found the solution!
Preface: View Controllers have an assumed size. (the size of your phone's screen). That's why whenever I presented a view added a view to the UIView it was always 667 -(iPhone 6 Screen Size). So in order to fix that I did this:
code :
if selectedIndex == 0 {

        vc.view.frame.size.height = 480

    }

    if selectedIndex == 1 {

        vc.view.frame.size.height = 448

    }

    if selectedIndex == 2 {

        vc.view.frame.size.height = 715

    }

    if selectedIndex == 3 {

        vc.view.frame.size.height = 480

    }

View Controller changes its height to the height of a Scroll View


By : imdna
Date : March 29 2020, 07:55 AM
hope this fix your issue You should be able to specify the second view controller's size by selecting it and choosing Simulated Size: Freeform option.

Set Dynamic Cell's Table View Content height to table view height constraints ios


By : Goker
Date : March 29 2020, 07:55 AM
I wish this helpful for you I have tableview(A)'s every custom cell having tableview(B) with dynamic table view cell. , Add the following code in you viewDidLoad method.

Table view cell height based upon Dynamic height Table Height issues


By : Erik E
Date : March 29 2020, 07:55 AM
Does that help Please tryout tableView.layoutIfNeeded() before returning return tableView.frame.size.height/2
Related Posts Related Posts :
  • Why does Firestore sometimes not return anything, no error, nothing?
  • How to trigger a segue from a tab bar item to another by clicking a button?
  • How to instantiate a nib into view without a viewcontroller as owner?
  • How can I pass a Post Id to a Comments VC - Swift
  • typealias is not able to use producing Cannot invoke initializer Error
  • Different values for print or console print out
  • How to create TextField for message input with 0 lines?
  • How can I make a cell and its elements look greyed out?
  • What is a viable alternative for a Dictionary for Search applications in Swift?
  • User is already logged in and save data into core data using api
  • Find an element in a stack data structure swift 4
  • Tap Gesture not working as expected when added to uiview in collectionview cell
  • "No WatchKit 1.0 app bundle found for app" Xcode 10.1 Swift 4.2
  • UISearchBar in UITableView by Rxswift
  • Cannot convert value of type '[Int]' to expected argument type 'Int'
  • How to test view controller with XIB file using Quick?
  • Local and Network Data Manager
  • Change barbutton image
  • Can not scroll to a row of a section in a tableView
  • Cannot use instance member 'getA' within property initializer; property initializers run before 'self' is available
  • shadow
    Privacy Policy - Terms - Contact Us © voile276.org