0

So i have this app and on the first open i want it to show a quick start page. The code i have to initiate and work out if its there first open is

let savedData = NSUserDefaults(suiteName: "xxx")

    if savedData?.boolForKey("firstTimeUser") == nil {
        savedData?.setObject(true, forKey: "firstTimeUser")
        savedData?.synchronize()
        print("Hello")
    }
    if savedData?.boolForKey("firstTimeUser") == true {

      //Code to show view controller! Help :)

        savedData?.setBool(false, forKey: "firstTimeUser")
        savedData?.synchronize()
    }

I have a NSViewController on my main.storyboard and i want it to present it self as a sperate window that the user can close after they have finished reading it. Im thinking i have to use a storyboard id but iv gotten lost and need help! Thanks in advance!

Eli
  • 668
  • 2
  • 13
  • 37

0 Answers0