I cannot use webview.loadurl in android eclipse
Import like this
import android.os.Bundle;
import android.app.Activity;
import android.view.Menu;
import android.webkit.WebView;
import android.webkit.WebSettings;
import android.webkit.WebViewClient;
and then:
WebView myWebView = (WebView) findViewById(R.id.web1);
myWebView.loadUrl("http://www.example.com");
But the it shows errors for line
"myWebView.loadUrl("http://www.example.com");"
Multiple markers at this line - Syntax error on token
""http://google.com"", delete this token - Syntax error on token(s),
misplaced construct(s)
What's wrong with me?
No comments:
Post a Comment