# 🎤 General Discussion

**URL:** https://forums.kodeco.com/c/general/16.md?page=70

[Latest](https://forums.kodeco.com/latest.md) · [Categories](https://forums.kodeco.com/categories.md) · [Tags](https://forums.kodeco.com/tags.md)

**Page:** 71

---

## [Print top 2 highest scores in dictonary](https://forums.kodeco.com/t/print-top-2-highest-scores-in-dictonary/35224)

<div class="topic-metadata">

**Author:** [@timswift](https://forums.kodeco.com/u/timswift)\
**Replies:** 2\
**Last updated:** [October 25, 2017, 6:57am UTC](https://forums.kodeco.com/t/print-top-2-highest-scores-in-dictonary/35224 "2017-10-25T06:57:44Z")

</div>

The code prints out the highest score in the dictionary. How can I print the 2nd highest score as well. I want to print the top 2 scores. import UIKit var people: \[\[String:Any\]\] = \[ \[ "firstName": "Sam", "…

---

## [Login Google SignIn](https://forums.kodeco.com/t/login-google-signin/35541)

<div class="topic-metadata">

**Author:** [@jack7](https://forums.kodeco.com/u/jack7)\
**Replies:** 1\
**Last updated:** [October 25, 2017, 6:48am UTC](https://forums.kodeco.com/t/login-google-signin/35541 "2017-10-25T06:48:33Z")

</div>

Hi, I need to log in with Google Sign-In for iOS. My App is both in Obj-C and Swift. The login viewcontroller is in Swift, but the AppDelegate is in Obj-C. I followed the guide of Google: I have imported the library …

---

## [Struct not keeping sorted order (swift4)](https://forums.kodeco.com/t/struct-not-keeping-sorted-order-swift4/35060)

<div class="topic-metadata">

**Author:** [@timswift](https://forums.kodeco.com/u/timswift)\
**Replies:** 1\
**Last updated:** [October 25, 2017, 6:45am UTC](https://forums.kodeco.com/t/struct-not-keeping-sorted-order-swift4/35060 "2017-10-25T06:45:05Z")

</div>

My code has 2 textfields one for int and the other for string. The way the code is supposed to be sorted is by ascending alphabetical order for the string (a-z)then by descending order for the int (9-1).So i entered 2 en…

---

## [How to save entry to struct (swift4)](https://forums.kodeco.com/t/how-to-save-entry-to-struct-swift4/35290)

<div class="topic-metadata">

**Author:** [@timswift](https://forums.kodeco.com/u/timswift)\
**Replies:** 1\
**Last updated:** [October 25, 2017, 6:32am UTC](https://forums.kodeco.com/t/how-to-save-entry-to-struct-swift4/35290 "2017-10-25T06:32:52Z")

</div>

Right now my code prints the struct that was entered, but it can only print the last individual entry entered. It can only store 1 entry. How can I store and print every entry in the struct. import UIKi…

---

## [How do I measure the distance between two CGPoint objects?](https://forums.kodeco.com/t/how-do-i-measure-the-distance-between-two-cgpoint-objects/35896)

<div class="topic-metadata">

**Author:** [@brower](https://forums.kodeco.com/u/brower)\
**Replies:** 1\
**Last updated:** [October 25, 2017, 4:53am UTC](https://forums.kodeco.com/t/how-do-i-measure-the-distance-between-two-cgpoint-objects/35896 "2017-10-25T04:53:11Z")

</div>

Is there a convenient way in iOS to measure the distance between two CGPoint objects on a view and test whether the distance comes withing a certain range?

---

## [Updating MKMapView while UITableView is scrolling, obtaining coordinates from cell](https://forums.kodeco.com/t/updating-mkmapview-while-uitableview-is-scrolling-obtaining-coordinates-from-cell/35869)

<div class="topic-metadata">

**Author:** [@durul](https://forums.kodeco.com/u/durul)\
**Replies:** 8\
**Last updated:** [October 25, 2017, 2:25am UTC](https://forums.kodeco.com/t/updating-mkmapview-while-uitableview-is-scrolling-obtaining-coordinates-from-cell/35869 "2017-10-25T02:25:57Z")

</div>

Hello, I have an UIViewController containing a MKMapView and an UITableView. Each cell in the tableView contains a set of coordinates. If you want to see, please check this screenshot I want to the update MKMapView “in…

---

## [Mac OS Webview HTML string is blank](https://forums.kodeco.com/t/mac-os-webview-html-string-is-blank/35630)

<div class="topic-metadata">

**Author:** [@nhr](https://forums.kodeco.com/u/nhr)\
**Replies:** 4\
**Last updated:** [October 24, 2017, 6:09pm UTC](https://forums.kodeco.com/t/mac-os-webview-html-string-is-blank/35630 "2017-10-24T18:09:09Z")

</div>

Here is the simple code that works in xcode 8 but does not work(blank screen) on Xcode 9. Tried changing App Transport settings - Allow Arbitary loads to “YES”. Still not working. Any suggestions on how to fix this? im…

---

## [Parsing notification message to string format](https://forums.kodeco.com/t/parsing-notification-message-to-string-format/35613)

<div class="topic-metadata">

**Author:** [@samerhameed](https://forums.kodeco.com/u/samerhameed)\
**Replies:** 3\
**Last updated:** [October 22, 2017, 2:45am UTC](https://forums.kodeco.com/t/parsing-notification-message-to-string-format/35613 "2017-10-22T02:45:20Z")

</div>

Dear sir, I used the below function to print the notification message func application(\_ application: UIApplication, didReceiveRemoteNotification userInfo: \[AnyHashable: Any\]) { print(userInfo) } I need to parse the…

---

## [Xcode9 migrate project from swift3 to swift4](https://forums.kodeco.com/t/xcode9-migrate-project-from-swift3-to-swift4/34640)

<div class="topic-metadata">

**Author:** [@haowu](https://forums.kodeco.com/u/haowu)\
**Replies:** 3\
**Last updated:** [October 21, 2017, 10:20am UTC](https://forums.kodeco.com/t/xcode9-migrate-project-from-swift3-to-swift4/34640 "2017-10-21T10:20:59Z")

</div>

Hi，I get some errors when I migrate the app “Groundhog”(WatchOS by Tutorials, Chapter 23, HealKit) from swift 3 to swift 4. After I migrate the code to swift 4, when I build this project, Xcode 9 reports these errors in…

---

## [Pygame for Mac OS Sierra](https://forums.kodeco.com/t/pygame-for-mac-os-sierra/24726)

<div class="topic-metadata">

**Author:** [@dkdamonse](https://forums.kodeco.com/u/dkdamonse)\
**Replies:** 11\
**Last updated:** [January 3, 2017, 1:25pm UTC](https://forums.kodeco.com/t/pygame-for-mac-os-sierra/24726 "2017-01-03T13:25:05Z")

</div>

Hey, I’ve been trying to download pygame from its website but none of the options have been working and I realised that the downloads are only meant for Mac OSX, but I have Mac OS Sierra. Is that maybe the problem? I don…

---

## [Changing loading template style in TVML](https://forums.kodeco.com/t/changing-loading-template-style-in-tvml/35722)

<div class="topic-metadata">

**Author:** [@cesarcarlos](https://forums.kodeco.com/u/cesarcarlos)\
**Replies:** 0\
**Last updated:** [October 19, 2017, 5:31pm UTC](https://forums.kodeco.com/t/changing-loading-template-style-in-tvml/35722 "2017-10-19T17:31:34Z")

</div>

Hi, I was wondering if there is a way of changing the TVML loadingTemplate so that it has a dark background and white text. Currently the default is black text on top of light gray background. I tried but this only cha…

---

## [Custom error message in TVML](https://forums.kodeco.com/t/custom-error-message-in-tvml/35721)

<div class="topic-metadata">

**Author:** [@cesarcarlos](https://forums.kodeco.com/u/cesarcarlos)\
**Replies:** 1\
**Last updated:** [October 19, 2017, 4:57pm UTC](https://forums.kodeco.com/t/custom-error-message-in-tvml/35721 "2017-10-19T16:57:38Z")

</div>

Hello, I’m working on a TVML app. Everything is working fine, but one of the videos playing is a live stream which is only available at certain hours of the day. If the feed is not available and I try to play it, I get …

---

## [Are records created in CloudKit also created in the user's iCloud account or do they reside on the developer's iCloud account?](https://forums.kodeco.com/t/are-records-created-in-cloudkit-also-created-in-the-users-icloud-account-or-do-they-reside-on-the-developers-icloud-account/35536)

<div class="topic-metadata">

**Author:** [@brower](https://forums.kodeco.com/u/brower)\
**Replies:** 2\
**Last updated:** [October 18, 2017, 10:51pm UTC](https://forums.kodeco.com/t/are-records-created-in-cloudkit-also-created-in-the-users-icloud-account-or-do-they-reside-on-the-developers-icloud-account/35536 "2017-10-18T22:51:38Z")

</div>

Are records created in CloudKit also created in the user’s iCloud account when the app is installed or do they reside on the developer’s iCloud account?

---

## [Do I need PaintCode?](https://forums.kodeco.com/t/do-i-need-paintcode/35617)

<div class="topic-metadata">

**Author:** [@afinque](https://forums.kodeco.com/u/afinque)\
**Replies:** 2\
**Last updated:** [October 17, 2017, 10:37pm UTC](https://forums.kodeco.com/t/do-i-need-paintcode/35617 "2017-10-17T22:37:04Z")

</div>

Hi, I’m still fairly new to iOS development, and I just discovered PaintCode. I tried the demo and it seems pretty cool, but do I really need it? Will Xcode 9 do all of the scaling for me, obviating the need for PaintCod…

---

## [Resolution not right](https://forums.kodeco.com/t/resolution-not-right/35589)

<div class="topic-metadata">

**Author:** [@jfortyork](https://forums.kodeco.com/u/jfortyork)\
**Replies:** 4\
**Last updated:** [October 17, 2017, 5:53pm UTC](https://forums.kodeco.com/t/resolution-not-right/35589 "2017-10-17T17:53:52Z")

</div>

Hello, I’m trying to build a simple tip calculator in XCode, but it seems that the resolution of my button images in the iPhone 8 Plus simulator appear pixelated. The images appear fine in the iPhone 7 or less simulato…

---

## [A strutured way to organize and work my data](https://forums.kodeco.com/t/a-strutured-way-to-organize-and-work-my-data/35644)

<div class="topic-metadata">

**Author:** [@forrequi](https://forums.kodeco.com/u/forrequi)\
**Replies:** 1\
**Last updated:** [October 17, 2017, 5:05pm UTC](https://forums.kodeco.com/t/a-strutured-way-to-organize-and-work-my-data/35644 "2017-10-17T17:05:36Z")

</div>

Hi, thanks for read this. I’m writing a iOS app to take care about local motorcycle race events. Each event have 3 stages and about 50 pilots. I’ve defining a structure for pilots data (name, lastName, number, etc), and…

---

## [Adding push notification to exist App](https://forums.kodeco.com/t/adding-push-notification-to-exist-app/35574)

<div class="topic-metadata">

**Author:** [@samerhameed](https://forums.kodeco.com/u/samerhameed)\
**Replies:** 5\
**Last updated:** [October 16, 2017, 6:57pm UTC](https://forums.kodeco.com/t/adding-push-notification-to-exist-app/35574 "2017-10-16T18:57:00Z")

</div>

Dear Sir, I have an App published in the store without push notification, now I want to update a new version for this App to include thus feature. I searched in the net and all the articles I found talks about how to s…

---

## [Capturing contact street, city, stqte, zipcode from contact details in iOS Xcode 8](https://forums.kodeco.com/t/capturing-contact-street-city-stqte-zipcode-from-contact-details-in-ios-xcode-8/35371)

<div class="topic-metadata">

**Author:** [@twglodek](https://forums.kodeco.com/u/twglodek)\
**Replies:** 1\
**Last updated:** [October 13, 2017, 4:44pm UTC](https://forums.kodeco.com/t/capturing-contact-street-city-stqte-zipcode-from-contact-details-in-ios-xcode-8/35371 "2017-10-13T16:44:54Z")

</div>

I am writing some code in Xcode 8 that allows the user to select a contact, then have that contacts name, street, city, state, country, and zipcode populate into a label on the view controller then pass that information …

---

## [Certificate Signing Request(CSR) in swift using Secure Enclave](https://forums.kodeco.com/t/certificate-signing-request-csr-in-swift-using-secure-enclave/14836)

<div class="topic-metadata">

**Author:** [@cheetah2000](https://forums.kodeco.com/u/cheetah2000)\
**Replies:** 2\
**Last updated:** [October 11, 2017, 4:17pm UTC](https://forums.kodeco.com/t/certificate-signing-request-csr-in-swift-using-secure-enclave/14836 "2017-10-11T16:17:24Z")

</div>

I am looking for help to write the certificate signing request in swift. I am able to create a keys(private & public) in the secure enclave and able to access through keychain. Just, looking help for certificate signing …

---

## [What is the best way to learn unity's C# API?](https://forums.kodeco.com/t/what-is-the-best-way-to-learn-unitys-c-api/35502)

<div class="topic-metadata">

**Author:** [@supajbro](https://forums.kodeco.com/u/supajbro)\
**Replies:** 1\
**Last updated:** [October 12, 2017, 12:26pm UTC](https://forums.kodeco.com/t/what-is-the-best-way-to-learn-unitys-c-api/35502 "2017-10-12T12:26:25Z")

</div>

I have watched all of the C# tutorials on this site and found the videos extremely helpful. I have not really learnt anything on the API side though. Today I bought the ‘Unity Games By Tutorials’ book. I bought physical …

---

## [Crop photo taken from camera](https://forums.kodeco.com/t/crop-photo-taken-from-camera/35300)

<div class="topic-metadata">

**Author:** [@rufy](https://forums.kodeco.com/u/rufy)\
**Replies:** 1\
**Last updated:** [October 11, 2017, 8:01pm UTC](https://forums.kodeco.com/t/crop-photo-taken-from-camera/35300 "2017-10-11T20:01:53Z")

</div>

Hi everyone, i’ve create an custom camera that has an view controller with that the user can select the portion of photo to take. like a cropper. the problem is that the taken photo is bigger than camera and when try to…

---

## [Storyboard reference to a different project](https://forums.kodeco.com/t/storyboard-reference-to-a-different-project/35342)

<div class="topic-metadata">

**Author:** [@cleversou](https://forums.kodeco.com/u/cleversou)\
**Replies:** 4\
**Last updated:** [October 11, 2017, 4:44pm UTC](https://forums.kodeco.com/t/storyboard-reference-to-a-different-project/35342 "2017-10-11T16:44:29Z")

</div>

I’m having a difficult time trying to figuring out how to make a storyboard reference work with storyboard from other project. I’m trying to modularize my App, so I’m creating multiple projects inside Xcode workspace. Th…

---

## [CloudKit Database](https://forums.kodeco.com/t/cloudkit-database/35459)

<div class="topic-metadata">

**Author:** [@jmanderson](https://forums.kodeco.com/u/jmanderson)\
**Replies:** 0\
**Last updated:** [October 11, 2017, 1:03pm UTC](https://forums.kodeco.com/t/cloudkit-database/35459 "2017-10-11T13:03:47Z")

</div>

Is it possible to delete a database from the default CloudKit container? I have some that are unused.

---

## [Linking a static or dynamic library to a project in a workspace?](https://forums.kodeco.com/t/linking-a-static-or-dynamic-library-to-a-project-in-a-workspace/35454)

<div class="topic-metadata">

**Author:** [@baltrunas](https://forums.kodeco.com/u/baltrunas)\
**Replies:** 0\
**Last updated:** [October 11, 2017, 10:25am UTC](https://forums.kodeco.com/t/linking-a-static-or-dynamic-library-to-a-project-in-a-workspace/35454 "2017-10-11T10:25:22Z")

</div>

I’ve done this before, several years ago with Xcode 5 or 6. Now using Xcode 8 or 9, I seem to be missing someting. No matter what I’v done, when I try to build and link my project, I get the Linker message: Undefined …

---

## [Performance issues](https://forums.kodeco.com/t/performance-issues/35043)

<div class="topic-metadata">

**Author:** [@nehemie](https://forums.kodeco.com/u/nehemie)\
**Replies:** 5\
**Last updated:** [October 11, 2017, 5:59am UTC](https://forums.kodeco.com/t/performance-issues/35043 "2017-10-11T05:59:43Z")

</div>

Hi everyone I am building a Game using SpriteKit, this game is like Mario Run and has short levels (120 at the moment) and here is how it is organized : MenuScene\>LevelScene\>GameScene I do try to fix performance issu…

---

## [How to remove \[\] from print struct](https://forums.kodeco.com/t/how-to-remove-from-print-struct/35357)

<div class="topic-metadata">

**Author:** [@timswift](https://forums.kodeco.com/u/timswift)\
**Replies:** 2\
**Last updated:** [October 9, 2017, 8:36pm UTC](https://forums.kodeco.com/t/how-to-remove-from-print-struct/35357 "2017-10-09T20:36:08Z")

</div>

My Code below prints a struct its how I want it expect for the \[\]. I just want it removed. var contacts = \[Person\]() @IBAction func press(\_ sender: Any) { contacts.append(Person(name: a.text!, ph…

---

## [After updating OS to high Sierra, Xcode to 9 ... sprite kit issues](https://forums.kodeco.com/t/after-updating-os-to-high-sierra-xcode-to-9-sprite-kit-issues/35305)

<div class="topic-metadata">

**Author:** [@cybershoggy](https://forums.kodeco.com/u/cybershoggy)\
**Replies:** 2\
**Last updated:** [October 9, 2017, 8:22am UTC](https://forums.kodeco.com/t/after-updating-os-to-high-sierra-xcode-to-9-sprite-kit-issues/35305 "2017-10-09T08:22:49Z")

</div>

Hello, A game made recently with Swift 3 was working perfectly until Xcode was updated. Now sprites aren’t loaded and displayed, and other problems. I tried to write a program to initialise an SKSpriteNode with a sprit…

---

## [Porting Android app to IOS](https://forums.kodeco.com/t/porting-android-app-to-ios/35323)

<div class="topic-metadata">

**Author:** [@sgiddings](https://forums.kodeco.com/u/sgiddings)\
**Replies:** 2\
**Last updated:** [October 9, 2017, 6:44am UTC](https://forums.kodeco.com/t/porting-android-app-to-ios/35323 "2017-10-09T06:44:59Z")

</div>

I have built an android tablet application which has a certain success and have received numerous requests for it to be available equally on iPad. The application renders music scores directly in a custom view (this is n…

---

## [Why we need the synchronous operation in ios](https://forums.kodeco.com/t/why-we-need-the-synchronous-operation-in-ios/25004)

<div class="topic-metadata">

**Author:** [@lohanrakesh](https://forums.kodeco.com/u/lohanrakesh)\
**Replies:** 2\
**Last updated:** [October 8, 2017, 11:18am UTC](https://forums.kodeco.com/t/why-we-need-the-synchronous-operation-in-ios/25004 "2017-10-08T11:18:10Z")

</div>

Hello Friends I want to know As we all know how asynchronous task are necessary for concurrency but Wanted to know why we need the synchronous tasks. while we can achieve the same with the normal usage of function. Tha…

---

## [Difference between native & hybrid app?](https://forums.kodeco.com/t/difference-between-native-hybrid-app/33507)

<div class="topic-metadata">

**Author:** [@jennysmith](https://forums.kodeco.com/u/jennysmith)\
**Replies:** 8\
**Last updated:** [October 6, 2017, 7:23pm UTC](https://forums.kodeco.com/t/difference-between-native-hybrid-app/33507 "2017-10-06T19:23:14Z")

</div>

There are still many misconceptions about native and hybrid app development especially when it comes to mobile. like i unable to decide, to develop native app or hybrid app?

[Previous page](https://forums.kodeco.com/c/general/16.md?page=69)

[Next page](https://forums.kodeco.com/c/general/16.md?page=71)
