Avatar ·

Xcode中的错误“无法打开文件'MyApp.app',因为您没有查看权限”

大家好!我是Swift和Xcode的新手,遇到了一个非常奇怪的问题。我使用Xcode 6 Beta 4,编写一个简单的Swift应用程序。当我点击Run(▶️)按钮时,构建成功,Xcode显示“Build Succeeded”,但随后出现一个错误对话框: “The file 'MyApp.app' couldn't be opened because you don't have permission to view it.” 这是我的简单代码(ViewController.swift文件): ```swift import UIKit class ViewController: UIViewController { override func viewDidLoad() { super.viewDidLoad() let label = UILabel(frame: CGRect(x: 100, y: 100, width: 200, height: 50)) label.text = "Hello, Swift!" label.textColor = UIColor.black self.view.addSubview(label) } } ``` 没什么复杂的,就是一个普通的标签。应用程序甚至没有启动——只是弹出这个错误。我检查了Code Signing设置,那里都设置为“iOS Developer”。我尝试清理项目(Product → Clean),删