我是全新的Xcode 4.4和AppleScriptObjC。我試圖在Sanderson和Rosenthal的書「Learn AppleScript」中擴展和試驗AppleScriptObjC的教程,並且遇到了一個問題。代碼:Xcode/AppleScriptObjC新手
property parent : class "NSObject"
property textField : missing value
on buttonClick_(sender)
set theText to textField's stringValue()
set dialogText to text returned of (display dialog "Here is the text your entered: " & return & theText default answer "")
textfield's setStringValue_(dialogText)
end buttonClick
運行完美,我得到預期的對話框,並且一切正常。但是,如果我試圖勾搭,並添加以下兩行(在適當的地方,當然):
property anotherTextField : missing value
...
set theText to textField's stringValue() & otherTextField's stringValue()
程序仍然運行 - 但! - 如果我轉到MainMenu.xib並按住Ctrl的同時單擊AppDelegate以獲取網點檢查器...即使應該有另一個文本字段,也沒有Outlet。
任何想法?
不是線索;這對我來說工作得很好...... – geowar
我遇到同樣的問題你有沒有找到解決方案? –