我仍然有WebKit的教程中,我從蘋果公司的網站試圖麻煩: http://developer.apple.com/library/mac/#documentation/Cocoa/Conceptual/DisplayWebContent/Tasks/MultipleWindows.html預期「;」之前「{」令牌?
.h文件如下:
#import <Cocoa/Cocoa.h>
#import <WebKit/WebKit.h>
@interface MyDocument : NSDocument
{
IBOutlet id webView;
IBOutlet id textField;
}
- (IBAction)connectURL:(id)sender //Provides me with the error 'Expected ";" before "{" token'
{
[[webView mainFrame] loadRequest:[NSURLRequest requestWithURL:[NSURL URLWithString:[sender stringValue]]]];
}
@end
你能看到什麼是錯和爲什麼它給我一個問題,請好嗎?
- 謝謝!
謝謝,山姆! – 2010-12-08 15:13:48
沒問題!如果這回答你的問題,你介意按我的答案打勾? – 2010-12-08 15:14:23