[swift-users] reading data from a table in swift

Paul contestpaul at icloud.com
Sat Nov 26 14:33:59 CST 2016


Hi

I am almost a complete noob to Swift and I am writing my first app.

I need to read a value from a table and return that to the app to do a few calculations but I am so new I have no idea what is the best method to do this.

Specifically there are two tables (currently in microsoft excel) that i need to “read” and get a value from . The values in these tables never change so I can convert them into an array or other data structure that would make sense in Swift.

The first table is about 25 x 25 (rows and columns).

I need to read down the first column (A) to find the value that is equal to or the next larger value from what the user had input, and then I read across the first row (1) to find the value that is equal to or the next larger value. The cell where the row and column intersect contains a value and I want to extract that value and use it in a few calculations.

Can anyone help point me in a direction to get started with that?

The second table is 20 X 13 (rows v columns).

Similar to the first table, I need to read down the first column (A) to find the value that is equal to or the next larger value from what the user had input…unlike the first table, now I have to read across that specified row to find a cell value that is equal to or the next larger value to what the user input, and then read up to the column to the top row and read the value from the cell in row (0)

Again, I would appreciate any help about how to accomplish this.


Thanks in advance


Paul
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.swift.org/pipermail/swift-users/attachments/20161126/32b2024b/attachment.html>


More information about the swift-users mailing list