2017-12-17 18 views
-1

こんにちは何が問題なのですか? ıスクロールビューをここに追加すると、アプリでエラーが発生します。スクロールビューの下と外にwebviewコードとバック(geri)ボタンを置く必要があります。私のアプリは機能しません。私はscrollviewを削除するときに、私のアプリは再びあなたが相対的なレイアウトやリニアレイアウトやにビューを配置する必要がview.so皆ıがscrollviewを使用しているときにエラーが発生する理由

<?xml version="1.0" encoding="utf-8"?> 
 
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android" 
 
    android:layout_width="fill_parent" 
 
    android:layout_height="fill_parent" 
 
    xmlns:tools="http://schemas.android.com/tools" 
 
    tools:context="com.example.user.myapplication.MainActivity" 
 
    android:orientation="horizontal"> 
 
<ScrollView 
 
    android:layout_width="match_parent" 
 
    android:layout_height="match_parent"> 
 
     <Button 
 
     android:id="@+id/bn" 
 
     android:layout_width="wrap_content" 
 
     android:layout_height="wrap_content" 
 
     android:text="bn" /> 
 
    <Button 
 
     android:id="@+id/deneme" 
 
     android:layout_width="wrap_content" 
 
     android:layout_height="wrap_content" 
 
     android:text="deneme" /> 
 
    <Button 
 
      android:id="@+id/denemeiki" 
 
      android:layout_width="wrap_content" 
 
      android:layout_height="wrap_content" 
 
      android:text="denemeiki" /> 
 
</ScrollView> 
 
    <Button 
 
     android:id="@+id/geri" 
 
     android:layout_width="wrap_content" 
 
     android:layout_height="wrap_content" 
 
     android:layout_alignParentBottom="true" 
 
     android:layout_marginBottom="30dp" 
 
     android:layout_alignParentRight="true" 
 
     android:text="geri" 
 
     /> 
 
    <WebView 
 
     android:id="@+id/simpleWebView" 
 
     android:layout_width="wrap_content" 
 
     android:layout_height="wrap_content" 
 
     android:layout_margin="20dp" /> 
 
</RelativeLayout>

+1

を表示してください。 –

+0

コンポーネントを正しく初期化しましたか? – InfZero

+0

私のエミュレータは動作しません。 "残念なことに私のアプリは停止"私にこのエラーを与える私はアンドロイドスタジオ3.0を使用 –

答えて

3

スクロールビューのみが持つことのできる子は1つのみ おかげで働きますスクロールビューでこの相対レイアウトを配置します。

+0

OK私は "geri"戻るボタンの下に置くことができますか? –

+0

あなたは "geri"の下にスクロールビューを配置したいbackボタン.am i right? –

+0

ı私の画面に戻るボタンを入れたい。 ı私の画面の下にボタンを表示したいと思っています。 –

関連する問題