# Swift

**URL:** https://forums.kodeco.com/c/general/swift/15.md?page=26

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

**Page:** 27

---

## [How to turn a static var string into array](https://forums.kodeco.com/t/how-to-turn-a-static-var-string-into-array/33981)

<div class="topic-metadata">

**Author:** [@timswift](https://forums.kodeco.com/u/timswift)\
**Replies:** 1\
**Last updated:** [September 3, 2017, 4:12pm UTC](https://forums.kodeco.com/t/how-to-turn-a-static-var-string-into-array/33981 "2017-09-03T16:12:56Z")

</div>

My code below is a string inside of a struct. How can do the exact same thing expect replace the string with a array. struct gv{ static var mystruct = \[String\](); }

---

## [Swift Apprentice](https://forums.kodeco.com/t/swift-apprentice/33487)

<div class="topic-metadata">

**Author:** [@coltkell](https://forums.kodeco.com/u/coltkell)\
**Replies:** 9\
**Last updated:** [August 31, 2017, 10:35am UTC](https://forums.kodeco.com/t/swift-apprentice/33487 "2017-08-31T10:35:59Z")

</div>

Chapter 19, page 301 in the book (not PDF reference page number): It says to import UUID? What exactly are you talking about? How do you go about doing this? Also, you cannot move forward in the playground as there a…

---

## [Update for Swift by Tutorials](https://forums.kodeco.com/t/update-for-swift-by-tutorials/21358)

<div class="topic-metadata">

**Author:** [@clararhea](https://forums.kodeco.com/u/clararhea)\
**Replies:** 6\
**Last updated:** [August 28, 2017, 6:40pm UTC](https://forums.kodeco.com/t/update-for-swift-by-tutorials/21358 "2017-08-28T18:40:34Z")

</div>

Hi, may be I missed the announcement somewhere but is the book Swift by Tutorials going to be updated for Swift 3? Cheers

---

## [How to called perform segue in viewdidload()](https://forums.kodeco.com/t/how-to-called-perform-segue-in-viewdidload/21895)

<div class="topic-metadata">

**Author:** [@poseidon](https://forums.kodeco.com/u/poseidon)\
**Replies:** 1\
**Last updated:** [August 28, 2017, 3:12pm UTC](https://forums.kodeco.com/t/how-to-called-perform-segue-in-viewdidload/21895 "2017-08-28T15:12:49Z")

</div>

can i call performsegue(with identifier) in viewdidload bcs the segue didnt perform… i also try self.storyboard?.instantiateViewController(withIdentifier: \<#T##String#\>) but did not working too… my condition right now …

---

## [Sample Firebase code is not working](https://forums.kodeco.com/t/sample-firebase-code-is-not-working/26122)

<div class="topic-metadata">

**Author:** [@swiftomaniac](https://forums.kodeco.com/u/swiftomaniac)\
**Replies:** 1\
**Last updated:** [August 28, 2017, 3:03pm UTC](https://forums.kodeco.com/t/sample-firebase-code-is-not-working/26122 "2017-08-28T15:03:39Z")

</div>

Anyone tried to run the sample code that is available at Firebase iOS Codelab Swift. I keep getting a SIGABRT error when I first try to run it. Any suggestions on how to move beyond that on Swift 3 / iOS10. Thank you s…

---

## [Video Tutorial: Introducing Concurrency - Compressor Source in Swift 3](https://forums.kodeco.com/t/video-tutorial-introducing-concurrency-compressor-source-in-swift-3/20457)

<div class="topic-metadata">

**Author:** [@pappmaschee](https://forums.kodeco.com/u/pappmaschee)\
**Replies:** 1\
**Last updated:** [August 28, 2017, 2:49pm UTC](https://forums.kodeco.com/t/video-tutorial-introducing-concurrency-compressor-source-in-swift-3/20457 "2017-08-28T14:49:43Z")

</div>

Hello, I am Martin and fairly new to swift. Started to work with the Video Tutorial: Introducing Concurrency - Running Xcode 8 I thought converting the source to swift 3 might work. It didn’t work out of the box, for me…

---

## [Xcode8 of debug memory graph issues](https://forums.kodeco.com/t/xcode8-of-debug-memory-graph-issues/23053)

<div class="topic-metadata">

**Author:** [@shanda9799](https://forums.kodeco.com/u/shanda9799)\
**Replies:** 1\
**Last updated:** [August 28, 2017, 12:30am UTC](https://forums.kodeco.com/t/xcode8-of-debug-memory-graph-issues/23053 "2017-08-28T00:30:05Z")

</div>

Hi guys, How are you? I am following ios 10 by tutorial and meet an issue in chapter 2 which I cannot solved. I am trying to debug through memory graph, but the backtrace only shows hexadecimal instead of supposed act…

---

## [iOS Apprentice 4 and Xcode 8](https://forums.kodeco.com/t/ios-apprentice-4-and-xcode-8/19750)

<div class="topic-metadata">

**Author:** [@jakbuz](https://forums.kodeco.com/u/jakbuz)\
**Replies:** 1\
**Last updated:** [August 28, 2017, 12:28am UTC](https://forums.kodeco.com/t/ios-apprentice-4-and-xcode-8/19750 "2017-08-28T00:28:03Z")

</div>

Hey, i know that iOS Apprentice 5 edition will hit Sep. 21. but I am learning from this books right now and wonder should I update my Xcode to version 8 now ? And still learn from iOS Apprentice 4th until 5th edition lau…

---

## [Print edition when? PDF limitations?](https://forums.kodeco.com/t/print-edition-when-pdf-limitations/22600)

<div class="topic-metadata">

**Author:** [@anon49889718](https://forums.kodeco.com/u/anon49889718)\
**Replies:** 1\
**Last updated:** [August 28, 2017, 12:21am UTC](https://forums.kodeco.com/t/print-edition-when-pdf-limitations/22600 "2017-08-28T00:21:58Z")

</div>

I hate double posting but when will swift 3 apprentice be available in print? Nobody has answered… PS: Does the PDF edition allow printing?

---

## [How to switch view controller programitcally](https://forums.kodeco.com/t/how-to-switch-view-controller-programitcally/21639)

<div class="topic-metadata">

**Author:** [@zalubski](https://forums.kodeco.com/u/zalubski)\
**Replies:** 1\
**Last updated:** [August 28, 2017, 12:18am UTC](https://forums.kodeco.com/t/how-to-switch-view-controller-programitcally/21639 "2017-08-28T00:18:40Z")

</div>

The following code cannot be changed a lot because the code is part of a nib. I just need 1 line of code that when ever cancelled is pressed the current page will be transformed back to the view controller. To go from pa…

---

## [Swift 3 code stuck in compiling](https://forums.kodeco.com/t/swift-3-code-stuck-in-compiling/26287)

<div class="topic-metadata">

**Author:** [@maannaash](https://forums.kodeco.com/u/maannaash)\
**Replies:** 1\
**Last updated:** [August 28, 2017, 12:14am UTC](https://forums.kodeco.com/t/swift-3-code-stuck-in-compiling/26287 "2017-08-28T00:14:06Z")

</div>

I did some refactoring in my swift 3 code but now my code is not even compiling. It is stuck in compiling and takes forever. My CPU usage goes really high so I feel either it is some infinite loop or some type reference …

---

## [Interface Builder Issues Xcode 8 with TableViewControllers](https://forums.kodeco.com/t/interface-builder-issues-xcode-8-with-tableviewcontrollers/21433)

<div class="topic-metadata">

**Author:** [@oochr1soo](https://forums.kodeco.com/u/oochr1soo)\
**Replies:** 1\
**Last updated:** [August 28, 2017, 12:12am UTC](https://forums.kodeco.com/t/interface-builder-issues-xcode-8-with-tableviewcontrollers/21433 "2017-08-28T00:12:05Z")

</div>

Ive been having some issues with the new xcode 8 in interface builder with Tables. If i create a table with a prototype cell, i cant seem to drag and drop labels or anything into the cells. I have to drag them over to t…

---

## [userDefualt not saving array](https://forums.kodeco.com/t/userdefualt-not-saving-array/33718)

<div class="topic-metadata">

**Author:** [@timswift](https://forums.kodeco.com/u/timswift)\
**Replies:** 6\
**Last updated:** [August 25, 2017, 10:19pm UTC](https://forums.kodeco.com/t/userdefualt-not-saving-array/33718 "2017-08-25T22:19:08Z")

</div>

My Code below adds another entry to the array if the button jux is pressed. However the new entry is not being saved. The entries that are already their are saved but I can get any new entries to be saved. VC1 …

---

## [Turn public var String into Global Array](https://forums.kodeco.com/t/turn-public-var-string-into-global-array/33707)

<div class="topic-metadata">

**Author:** [@timswift](https://forums.kodeco.com/u/timswift)\
**Replies:** 1\
**Last updated:** [August 25, 2017, 5:00pm UTC](https://forums.kodeco.com/t/turn-public-var-string-into-global-array/33707 "2017-08-25T17:00:45Z")

</div>

I am segueing a data from vc1 to vc2 however I can only store 1 data entry in a string so I have to turn it into in array. public var loneScore: String? How do I turn this code into an array?

---

## [Parsing JSON objects](https://forums.kodeco.com/t/parsing-json-objects/12700)

<div class="topic-metadata">

**Author:** [@jonny](https://forums.kodeco.com/u/jonny)\
**Replies:** 5\
**Last updated:** [August 24, 2017, 3:51am UTC](https://forums.kodeco.com/t/parsing-json-objects/12700 "2017-08-24T03:51:29Z")

</div>

Hi I have just started really getting into iOS and wondered if someone could tell me if this is short piece of code is decent or not? I am trying to parse some JSON which has the following format: \[ { "home": "Some Tea…

---

## [Is there anyway to use a loop to shorten this code](https://forums.kodeco.com/t/is-there-anyway-to-use-a-loop-to-shorten-this-code/33368)

<div class="topic-metadata">

**Author:** [@zalubski](https://forums.kodeco.com/u/zalubski)\
**Replies:** 2\
**Last updated:** [August 23, 2017, 8:16pm UTC](https://forums.kodeco.com/t/is-there-anyway-to-use-a-loop-to-shorten-this-code/33368 "2017-08-23T20:16:47Z")

</div>

This is the code I am trying to shorten. I would think there is a loop for it but I am not sure. piker1.tag = 1 piker2.tag = 2 piker3.tag = 3 piker4.tag = 4 piker5.tag = 5 …

---

## [How to override a buttons action using a if else statement](https://forums.kodeco.com/t/how-to-override-a-buttons-action-using-a-if-else-statement/24693)

<div class="topic-metadata">

**Author:** [@zalubski](https://forums.kodeco.com/u/zalubski)\
**Replies:** 2\
**Last updated:** [August 20, 2017, 9:10pm UTC](https://forums.kodeco.com/t/how-to-override-a-buttons-action-using-a-if-else-statement/24693 "2017-08-20T21:10:51Z")

</div>

My code below is a timer. Once 2 seconds is reached a button appears. Right now if you press the button disappears forever. I would like the button to reappear after 10 seconds. After 10 seconds is passed I would like to…

---

## [Where can i find resource folder](https://forums.kodeco.com/t/where-can-i-find-resource-folder/33284)

<div class="topic-metadata">

**Author:** [@almass](https://forums.kodeco.com/u/almass)\
**Replies:** 3\
**Last updated:** [August 20, 2017, 2:52pm UTC](https://forums.kodeco.com/t/where-can-i-find-resource-folder/33284 "2017-08-20T14:52:44Z")

</div>

Hello All, i hope all is well please where can i find the resource folder for book iOS Animations by tutorial (ios10 with swift3) thanks a lot

---

## [Avspeechsynthesizer reading local notification](https://forums.kodeco.com/t/avspeechsynthesizer-reading-local-notification/33454)

<div class="topic-metadata">

**Author:** [@timswift](https://forums.kodeco.com/u/timswift)\
**Replies:** 1\
**Last updated:** [August 19, 2017, 12:50pm UTC](https://forums.kodeco.com/t/avspeechsynthesizer-reading-local-notification/33454 "2017-08-19T12:50:45Z")

</div>

My goal is to create a app that will read the local notification to the user using avspeechsynsthisizer. I have tried this many times with messing around with app delegate which I do not know well, To try to get this to …

---

## [Code Signing Error in design-patterns-ios-using-swift](https://forums.kodeco.com/t/code-signing-error-in-design-patterns-ios-using-swift/33296)

<div class="topic-metadata">

**Author:** [@rkhillah](https://forums.kodeco.com/u/rkhillah)\
**Replies:** 2\
**Last updated:** [August 18, 2017, 3:12am UTC](https://forums.kodeco.com/t/code-signing-error-in-design-patterns-ios-using-swift/33296 "2017-08-18T03:12:08Z")

</div>

I get two (related) errors when building the project: Showing Recent Issues Check dependencies \*\*Code Signing Error:\*\* Signing for "RWBlueLibrary" requires a development team. Select a development team in the project…

---

## [Textfield nod adding together when called](https://forums.kodeco.com/t/textfield-nod-adding-together-when-called/33233)

<div class="topic-metadata">

**Author:** [@zalubski](https://forums.kodeco.com/u/zalubski)\
**Replies:** 1\
**Last updated:** [August 13, 2017, 6:29am UTC](https://forums.kodeco.com/t/textfield-nod-adding-together-when-called/33233 "2017-08-13T06:29:09Z")

</div>

My code is trying to take to textfields and add them together to a total textfield. If I assign the values in viewdidload it works but as soon as I change the values the score textfield is not updated. import UIKit …

---

## [New or unknown keywords in Swift 3.0](https://forums.kodeco.com/t/new-or-unknown-keywords-in-swift-3-0/29772)

<div class="topic-metadata">

**Author:** [@dhaneshgosai](https://forums.kodeco.com/u/dhaneshgosai)\
**Replies:** 20\
**Last updated:** [August 12, 2017, 9:40pm UTC](https://forums.kodeco.com/t/new-or-unknown-keywords-in-swift-3-0/29772 "2017-08-12T21:40:06Z")

</div>

Discussion regarding Usage of some New Keywords in Swift and How to use in dat to day coding and best way to use this keywords.

---

## [How to nest avspeechsynthisizier into sound file (swif3)](https://forums.kodeco.com/t/how-to-nest-avspeechsynthisizier-into-sound-file-swif3/33085)

<div class="topic-metadata">

**Author:** [@zalubski](https://forums.kodeco.com/u/zalubski)\
**Replies:** 1\
**Last updated:** [August 10, 2017, 7:41pm UTC](https://forums.kodeco.com/t/how-to-nest-avspeechsynthisizier-into-sound-file-swif3/33085 "2017-08-10T19:41:49Z")

</div>

I would like to be able to use avspeechsynthiesizer to create a sound file that can be played in other functions. Just like I could by importing a sound into Xcode. So I would like to use the button in my code below to s…

---

## [How to handle firebase transactions offline? Swift](https://forums.kodeco.com/t/how-to-handle-firebase-transactions-offline-swift/33104)

<div class="topic-metadata">

**Author:** [@bibscy](https://forums.kodeco.com/u/bibscy)\
**Replies:** 0\
**Last updated:** [August 8, 2017, 11:00pm UTC](https://forums.kodeco.com/t/how-to-handle-firebase-transactions-offline-swift/33104 "2017-08-08T23:00:09Z")

</div>

I am writing an IOS App in Swift and I am using Firebase as a database. In this app multiple users can simultaneously read a list of jobs . Depending on the boolean value of a job only one user should be allowed to writ…

---

## [Core Data and Login screen](https://forums.kodeco.com/t/core-data-and-login-screen/33008)

<div class="topic-metadata">

**Author:** [@mandic\_milos](https://forums.kodeco.com/u/mandic_milos)\
**Replies:** 1\
**Last updated:** [August 8, 2017, 5:14pm UTC](https://forums.kodeco.com/t/core-data-and-login-screen/33008 "2017-08-08T17:14:51Z")

</div>

Hello community, I am trying to create login screen with CoreData (don’t want to do that with Firebase) and need help about that. I need some tutorial or some project so i can figure how it works and how to do that? Tha…

---

## [Server side swift and creating a rest service](https://forums.kodeco.com/t/server-side-swift-and-creating-a-rest-service/31536)

<div class="topic-metadata">

**Author:** [@izzywizz](https://forums.kodeco.com/u/izzywizz)\
**Replies:** 4\
**Last updated:** [August 8, 2017, 12:41pm UTC](https://forums.kodeco.com/t/server-side-swift-and-creating-a-rest-service/31536 "2017-08-08T12:41:51Z")

</div>

I’m starting to grip with all things iOS and swift but I really want to know how to create web servers using swift. I am ashamed to admit it but I don’t really know much about servers, I think I understand how REST work…

---

## [GKSKNodeComponent](https://forums.kodeco.com/t/gksknodecomponent/31670)

<div class="topic-metadata">

**Author:** [@funkytomato](https://forums.kodeco.com/u/funkytomato)\
**Replies:** 2\
**Last updated:** [August 2, 2017, 12:59pm UTC](https://forums.kodeco.com/t/gksknodecomponent/31670 "2017-08-02T12:59:13Z")

</div>

I have completed the swift Monster game tutorial, implementing entity component based framework. Afterwards, I read about GKSKNodeComponent. It seems that this component class should be used instead of GKComponent for …

---

## [Change particle Color with animation](https://forums.kodeco.com/t/change-particle-color-with-animation/32747)

<div class="topic-metadata">

**Author:** [@maxbobzien](https://forums.kodeco.com/u/maxbobzien)\
**Replies:** 1\
**Last updated:** [July 30, 2017, 5:25pm UTC](https://forums.kodeco.com/t/change-particle-color-with-animation/32747 "2017-07-30T17:25:30Z")

</div>

Hi, I want to change the color of my particles in SCNParticleSystem from Color A to Color B using CABasicAnimation I am retrieving color A via let currentColor: UIColor = (targetColorSphereEmitterNode.particleSystems?…

---

## [Need Advice if I can build a Application to run on Mac and PC](https://forums.kodeco.com/t/need-advice-if-i-can-build-a-application-to-run-on-mac-and-pc/32679)

<div class="topic-metadata">

**Author:** [@hcri50](https://forums.kodeco.com/u/hcri50)\
**Replies:** 1\
**Last updated:** [July 30, 2017, 1:12am UTC](https://forums.kodeco.com/t/need-advice-if-i-can-build-a-application-to-run-on-mac-and-pc/32679 "2017-07-30T01:12:12Z")

</div>

Can I build a Application that could run on a Mac and on Windows? The reason I am asking is that I will have a year in half to build a application that will run be running on a Mac and PC. My past projects were done wi…

---

## [Best way to display list of data](https://forums.kodeco.com/t/best-way-to-display-list-of-data/32261)

<div class="topic-metadata">

**Author:** [@dpalme](https://forums.kodeco.com/u/dpalme)\
**Replies:** 3\
**Last updated:** [July 26, 2017, 1:50am UTC](https://forums.kodeco.com/t/best-way-to-display-list-of-data/32261 "2017-07-26T01:50:16Z")

</div>

I have a database table of data that I’m wanting to display in a list in an IOS app. So far it’s been written entirely in swift with no plans on changing that. I was looking at the table views, but not sure if that is …

[Previous page](https://forums.kodeco.com/c/general/swift/15.md?page=25)

[Next page](https://forums.kodeco.com/c/general/swift/15.md?page=27)
