Layout that will not load on device despite showing no errors

JamesSTW

New Member
I have a layout which is quite complex (it is for a crossword so each individual editText needs to be individually defined).It is a linear layout, with a text view at the top (needs to be outside scrollview so it remains on screen), then a scrollview inside this with a tablelayout containing all of the editTexts. Finally i have some buttons in a linear layout at the bottom of the scrollview. (see code below, with only the first row of the tablelayout defined for ease of reading.. note there are 15 rows)First question, why does this not load onto my device despite showing no errors in Eclipse? Is it too complex or poorly defined? Second question, am I doing this the stupid way? It feels as though I am but i can't think of any way to simplify it.\[code\]<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"xmlns:tools="http://schemas.android.com/tools"android:layout_width="fill_parent"android:layout_height="fill_parent"android:background="#000000"android:orientation="vertical" ><TextView android:id="@+id/txtHint" android:layout_width="fill_parent" android:layout_height="wrap_content" android:layout_marginLeft="15dp" android:layout_marginRight="15dp" android:gravity="center" android:text="Click on a square for a clue!" tools:context=".MainActivity" android:background="#FFFFFF" /><TextView android:layout_width="fill_parent" android:layout_height="15dp" android:background="#000000" /><ScrollView android:layout_width="fill_parent" android:layout_height="fill_parent" android:background="#000000" android:orientation="vertical" ><LinearLayout android:layout_width="fill_parent" android:layout_height="fill_parent" android:background="#000000" android:orientation="vertical" ><TableLayout android:layout_height="wrap_content" android:layout_width="fill_parent" > <TableRow> <EditText android:gravity="center" android:layout_marginLeft="10dp" android:id="@+id/box0101" android:layout_width="30dp" android:layout_height="30dp" android:background="@drawable/boxoutlineone" /> <EditText android:gravity="center" android:id="@+id/box0102" android:layout_width="30dp" android:layout_height="30dp" android:background="#000000" /> <EditText android:gravity="center" android:id="@+id/box0103" android:layout_width="30dp" android:layout_height="30dp" android:background="#000000" /> <EditText android:gravity="center" android:id="@+id/box0104" android:layout_width="30dp" android:layout_height="30dp" android:background="#000000" /> <EditText android:gravity="center" android:id="@+id/box0105" android:layout_width="30dp" android:layout_height="30dp" android:background="@drawable/boxoutlinetwo" /> <EditText android:gravity="center" android:id="@+id/box0106" android:layout_width="30dp" android:layout_height="30dp" android:background="#000000" /> <EditText android:gravity="center" android:id="@+id/box0107" android:layout_width="30dp" android:layout_height="30dp" android:background="#000000" /> <EditText android:gravity="center" android:id="@+id/box0108" android:layout_width="30dp" android:layout_height="30dp" android:background="#000000" /> <EditText android:gravity="center" android:id="@+id/box0109" android:layout_width="30dp" android:layout_height="30dp" android:background="#000000" /> <EditText android:gravity="center" android:id="@+id/box0110" android:layout_width="30dp" android:layout_height="30dp" android:background="#000000" /> </TableRow>\[/code\]** Then all the other editText rows** \[code\]<TextView android:layout_width="fill_parent" android:layout_height="15dp" android:background="#000000" /><Button android:id="@+id/btnHelp" android:layout_width="fill_parent" android:layout_height="wrap_content" android:layout_marginLeft="15dp" android:layout_marginRight="15dp" android:gravity="center" android:text="Click here to cheat!" tools:context=".MainActivity" android:background="#e6b121" /><TextView android:layout_width="fill_parent" android:layout_height="15dp" android:background="#000000" /><Button android:id="@+id/btnClear" android:layout_width="fill_parent" android:layout_height="wrap_content" android:layout_marginLeft="15dp" android:layout_marginRight="15dp" android:gravity="center" android:text="Click here to clear the board!" tools:context=".MainActivity" android:background="#e6b121" /><TextView android:layout_width="fill_parent" android:layout_height="15dp" android:background="#000000" /><Button android:id="@+id/btnFinish" android:layout_width="fill_parent" android:layout_height="wrap_content" android:layout_marginLeft="15dp" android:layout_marginRight="15dp" android:gravity="center" android:text="Click here to finish level!" tools:context=".MainActivity" android:background="#e6b121" /><TextView android:layout_width="fill_parent" android:layout_height="15dp" android:background="#000000" />\[/code\]
 
Back
Top