Ios swift multi-column table

In my application I need a table with many columns (I am using swift). I search on Google but I can't find anything useful.

This example on object c:

Example

Can you give me any docs, tutorials or anything else that can help me create such a table?

I'm thinking about webview, but what about native iOS? How to do it?

Thank!

+3


source to share


4 answers


I also need a table like this, and I couldn't find what I needed until the following:

Please check this awesome post: http://www.brightec.co.uk/blog/uicollectionview-using-horizontal-and-vertical-scrolling-sticky-rows-and-columns



Also you can go directly to the source code: https://github.com/brightec/CustomCollectionViewLayout

Implemented in obj-c and they migrated to swift recently. They use a UICollectionView as you can see the details from the post.

+2


source


Here are some good examples that provide a custom, native look for a multi-column table:

1) https://www.cocoacontrols.com/controls/scrollable-multicolumn-table-for-ipad



2) https://www.cocoacontrols.com/controls/asftableview

3) https://www.cocoacontrols.com/controls/multicolumntableviewforios

+1


source


you don't need custom controls (they are all for Objective C here). It is a simple TableView with CustomCells and Header Section.

You can use Autolayout to calculate the required height for each cell. Separate them on some labels and set constraints for the Prototype cell.

More details here:

http://www.weheartswift.com/how-to-make-a-simple-table-view-with-ios-8-and-swift/

Sections (its purpose is C, but you should be able to read the code and convert to swift)

http://www.ioscreator.com/tutorials/customizing-headers-footers-table-view-ios7

Custom table layout

http://www.ioscreator.com/tutorials/prototype-cells-tableview-tutorial-ios8-swift

+1


source


  • Have a look at ALGridView Link (it has a few limitations)

  • You can also use NGrid Link (note that it is not open source or used.)

+1


source







All Articles