Warning: file_get_contents(/data/phpspider/zhask/data//catemap/0/iphone/42.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Iphone 通过didFinishLaunchingWithOptions和调用ViewController webview预加载NSURL_Iphone_Ios_Webview_Nsurl_Preloader - Fatal编程技术网

Iphone 通过didFinishLaunchingWithOptions和调用ViewController webview预加载NSURL

Iphone 通过didFinishLaunchingWithOptions和调用ViewController webview预加载NSURL,iphone,ios,webview,nsurl,preloader,Iphone,Ios,Webview,Nsurl,Preloader,如果我的应用程序启动,我想通过“didFinishLaunchingWithOptions”预加载URL。 此时,我直接在ViewController中调用URL,但访问内容花费的时间太长,因此我希望直接从URL查看内容 此时在我的ViewController viewDidLoad: [URL-RESULT-show ] 因此,我想我必须在AppDelegate中创建一个方法。 - (void) callURL{ [myWebView loadRequest:[NSURLRequest re

如果我的应用程序启动,我想通过“didFinishLaunchingWithOptions”预加载URL。 此时,我直接在ViewController中调用URL,但访问内容花费的时间太长,因此我希望直接从URL查看内容

此时在我的ViewController viewDidLoad:

[URL-RESULT-show ]
因此,我想我必须在AppDelegate中创建一个方法。

- (void) callURL{
[myWebView loadRequest:[NSURLRequest requestWithURL:
[NSURL URLWithString:NSLocalizedString(@"URL_today",@"URL-Calendar")]]];
loadingTimer = [NSTimer scheduledTimerWithTimeInterval:(1.0/2.0) target:self selector:@selector(loading) userInfo:(nil) repeats:YES];}
然后调用“didFinishLaunchingWithOptions”中的方法

现在我必须在ViewController-viewDidLoad:

[URL-RESULT-show ]

有人有主意吗,怎么做?谢谢。

请提高您的接受率是的,您提出了18个问题,接受了5个。
[URL-RESULT-show ]