NSURL&#39?;没有会员'路径'

时间:2014-11-03 09:37:26

标签: swift

此代码曾用于Swift和Xcode Beta:

@IBAction func chooseTargerDir(sender: AnyObject) {

    let myFiledialog:NSOpenPanel = NSOpenPanel()
    myFiledialog.allowsMultipleSelection = false
    myFiledialog.canChooseDirectories = true
    myFiledialog.runModal()

    var chosenfile = myFiledialog.URL 
    arg2.stringValue = chosenfile.path

现在在Xcode 6.1中,我收到错误:

'NSURL?' does not have a member 'path'

0 个答案:

没有答案