I want to create a WebView
in View Controller.
I try to control-drag from WebView to ViewController.h
, but it is not showing me the blue connector.
Is there something I am missing?
Please help. Thank you.
PS I search keyword "web view connect" and "web view" on Apple Documentation, it is showing me WebKit
something like that. What is the keyword should I type?
Make sure of the following things:
1)Make sure that the .h file that you are control + dragging onto is the header file for your view controller. You can check this by checking the identity tab for your view controller in the utilities pane and making sure that the class name for the controller matches the header file name that you are control + dragging to.
2)Make sure that you are control + dragging in between the @interface and the @end like such:
@interface ViewController:UIViewController
// Control + Drag into this area
@end
Have you declared instance variable like IBOutlet _webView;
in your ViewController.h
file, if not, Xcode can't show blue connector.
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.