ブラウザーを呼び出すには
指定したURLに移動する
この方法はデフォルトのブラウザが呼び出され、指定したURLのページに移動する
Intent intent = new Intent(); intent.setAction(Intent.ACTION_VIEW); intent.setData(Uri.parse("http://www.yahoo.co.jp")); startActivity(intent);
ブラウザを選択してから、検索を行う
Intent intent = new Intent(); intent.setAction(Intent.ACTION_WEB_SEARCH); // 検索文字列は第2引数に入れる intent.putExtra(SearchManager.QUERY, "android"); startActivity(intent);