Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    text
    copied!<p>Change the name of the Layout file to <strong>cart.xml</strong></p> <p>When changed to the following format your sample runs</p> <pre><code>&lt;?xml version="1.0" encoding="utf-8"?&gt; &lt;TabHost xmlns:android="http://schemas.android.com/apk/res/android" android:id="@android:id/tabhost" android:layout_width="fill_parent" android:layout_height="fill_parent"&gt; &lt;LinearLayout android:orientation="vertical" android:layout_width="fill_parent" android:layout_height="fill_parent"&gt; &lt;TabWidget android:id="@android:id/tabs" android:layout_width="fill_parent" android:layout_height="wrap_content" /&gt; &lt;FrameLayout android:id="@android:id/tabcontent" android:layout_width="fill_parent" android:layout_height="fill_parent"&gt; &lt;LinearLayout android:id="@+id/addTab1a" android:layout_width="fill_parent" android:layout_height="fill_parent" android:orientation="vertical"&gt; &lt;TextView android:id="@+id/createCartNameLabel" android:layout_width="fill_parent" android:layout_height="wrap_content" android:text="CreateCartNameLabelText"/&gt; &lt;EditText android:id="@+id/enterCartName" android:layout_width="fill_parent" android:layout_height="wrap_content"/&gt; &lt;TextView android:id="@+id/createPriceLabel" android:layout_width="fill_parent" android:layout_height="wrap_content" android:text="PriceLabelText"/&gt; &lt;EditText android:id="@+id/enterPrice" android:layout_width="fill_parent" android:layout_height="wrap_content"/&gt; &lt;/LinearLayout&gt; &lt;LinearLayout android:id="@+id/addTab2" android:layout_width="fill_parent" android:layout_height="fill_parent" android:orientation="vertical"&gt; &lt;TextView android:id="@+id/createFruitLabel" android:layout_width="fill_parent" android:layout_height="wrap_content" android:text="CreateFruitLabelText"/&gt; &lt;EditText android:id="@+id/enterFruit" android:layout_width="fill_parent" android:layout_height="wrap_content"/&gt; &lt;/LinearLayout&gt; &lt;/FrameLayout&gt; &lt;/LinearLayout&gt; &lt;/TabHost&gt; </code></pre>
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload