WebViewを表示でページを出すアプリを作っています。
最後の}の後ろに;をつけろという意味でしょうか?
Fix-it insert";"
と出てくるのでそれに従って;をつけたのですが
そこでたくさん10個ぐらい足したのですが
それがずっと出続けます。
更につけていくと入れすぎです?という意味?
Fix-it delete";"
と出てしまいます。
そして1個ずつ減らしていくと
Fix-it insert";"
の表示が出てきてしまいます。
さらに減らすと
Expecetd dellaration
というのが出てきました。
Swift
1 2// Scarチュートリアル for iOS 3// 4// Created by こーたん on 2016/03/31. 5// Copyright © 2016年 こーたん. All rights reserved. 6// 7 8import UIKit 9 10@UIApplicationMain 11class AppDelegate: UIResponder, UIApplicationDelegate { 12 13 var window: UIWindow? 14 15 16 func application(application: UIApplication, didFinishLaunchingWithOptions launchOptions: [NSObject: AnyObject]?) -> Bool { 17 // Override point for customization after application launch. 18 return true 19 } 20 21 func applicationWillResignActive(application: UIApplication) { 22 // Sent when the application is about to move from active to inactive state. This can occur for certain types of temporary interruptions (such as an incoming phone call or SMS message) or when the user quits the application and it begins the transition to the background state. 23 // Use this method to pause ongoing tasks, disable timers, and throttle down OpenGL ES frame rates. Games should use this method to pause the game. 24 } 25 26 func applicationDidEnterBackground(application: UIApplication) { 27 // Use this method to release shared resources, save user data, invalidate timers, and store enough application state information to restore your application to its current state in case it is terminated later. 28 // If your application supports background execution, this method is called instead of applicationWillTerminate: when the user quits. 29 } 30 31 func applicationWillEnterForeground(application: UIApplication) { 32 // Called as part of the transition from the background to the inactive state; here you can undo many of the changes made on entering the background. 33 } 34 35 func applicationDidBecomeActive(application: UIApplication) { 36 // Restart any tasks that were paused (or not yet started) while the application was inactive. If the application was previously in the background, optionally refresh the user interface. 37 } 38 39 func applicationWillTerminate(application: UIApplication) { 40 // Called when the application is about to terminate. Save data if appropriate. See also applicationDidEnterBackground:. 41 } 42 43 44 class ViewController: UIViewController { 45 46 var webView: UIWebView? 47 48 var targetURL = "scarproject.github.io/operetion.html" 49 50 override func viewDidLoad() { 51 super.viewDidLoad() 52 53 54 // WebView表示 55 self.webView = self.createWebView() 56 57 // サブビュー 58 self.view.addSubview(self.webView!) 59 60 // リクエスト 61 let url = NSURL(string: targetURL) 62 let request = NSURLRequest(URL: url!) 63 64 // ページ読み込み 65 self.webView?.loadRequest(request) 66 } 67 68 69 func createWebView() -> UIWebView { 70 71 let _webView = UIWebView() 72 73 74 _webView.frame = self.view.bounds 75 76 return _webView 77 78 }
教えて下さい!
お願いします!m(_ _)m
回答1件
あなたの回答
tips
プレビュー
バッドをするには、ログインかつ
こちらの条件を満たす必要があります。
2016/03/31 04:59