I made a layout on TARGET SDK:17 and MİN SDK:8. it was ok. when it was on SDK:17 but when ı try it with SDK:8 it gave error at the bottom. can anyone tell me how can ı make work my code on SDK:8 Thank you for your helps. Here is the XML ....
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:gravity="center"
android:orientation="vertical" >
<TableLayout
android:layout_width="match_parent"
android:layout_height="match_parent"
tools:ignore="UselessParent" >
<TableRow
android:id="@+id/tableRow1"
android:layout_width="match_parent"
android:layout_height="match_parent" >
<TextView
android:id="@+id/textButtonBakici"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_weight="1"
android:text="@string/textBakici" />
<EditText
android:id="@+id/editTextBakici"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_span="3"
android:layout_weight="1"
android:hint="@string/altiyuzyirmibes"
android:inputType="numberDecimal" />
</TableRow>
<TableRow
android:id="@+id/tableRow2"
android:layout_width="wrap_content"
android:layout_height="wrap_content" >
<TextView
android:id="@+id/textKrediAraba"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_weight="1"
android:text="@string/textKrediAraba"/>
<EditText
android:id="@+id/editTextKrediAraba"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_span="3"
android:layout_weight="1"
android:hint="@string/besyuzdoksan"
android:inputType="numberDecimal" />
</TableRow>
<TableRow
android:id="@+id/tableRow3"
android:layout_width="wrap_content"
android:layout_height="wrap_content" >
<TextView
android:id="@+id/textOgrenimKredisi"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_weight="1"
android:text="@string/textOgrenimKredisi" />
<EditText
android:id="@+id/editTextOgrenimKredisi"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_span="3"
android:layout_weight="1"
android:hint="@string/dortyuzon"
android:inputType="numberDecimal" />
</TableRow>
<TableRow
android:id="@+id/tableRow4"
android:layout_width="wrap_content"
android:layout_height="wrap_content" >
<TextView
android:id="@+id/textTatilKredisi"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_weight="1"
android:text="@string/textTatilKredisi"/>
<EditText
android:id="@+id/editTextTatilKredisi"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_span="3"
android:layout_weight="1"
android:hint="@string/yuzotuzbes"
android:inputType="numberDecimal" />
</TableRow>
<TableRow
android:id="@+id/tableRow5"
android:layout_width="match_parent"
android:layout_height="match_parent" >
<TextView
android:id="@+id/textFaturaElektrik"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_weight="1"
android:text="@string/textFaturaElektrik" />
<EditText
android:id="@+id/editTextFaturaElektrik"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_span="3"
android:layout_weight="1"
android:hint="@string/sifir"
android:inputType="numberDecimal" />
</TableRow>
<TableRow
android:id="@+id/tableRow6"
android:layout_width="match_parent"
android:layout_height="match_parent" >
<TextView
android:id="@+id/textFaturaSu"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_weight="1"
android:text="@string/textFaturaSu" />
<EditText
android:id="@+id/editTextFaturaSu"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_span="3"
android:layout_weight="1"
android:hint="@string/sifir"
android:inputType="numberDecimal" />
</TableRow>
<TableRow
android:id="@+id/tableRow7"
android:layout_width="match_parent"
android:layout_height="match_parent" >
<TextView
android:id="@+id/textFaturaInternet"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_weight="1"
android:text="@string/textFaturaInternet" />
<EditText
android:id="@+id/editTextFaturaInternet"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_span="3"
android:layout_weight="1"
android:hint="@string/otuz"
android:inputType="numberDecimal" />
</TableRow>
<TableRow
android:id="@+id/tableRow8"
android:layout_width="match_parent"
android:layout_height="match_parent" >
<TextView
android:id="@+id/textAidat"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_weight="1"
android:text="@string/textAidat"/>
<EditText
android:id="@+id/editTextAidat"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_span="3"
android:layout_weight="1"
android:hint="@string/sifir"
android:inputType="numberDecimal" />
</TableRow>
<TableRow
android:id="@+id/tableRow9"
android:layout_width="match_parent"
android:layout_height="match_parent" >
<TextView
android:id="@+id/textKaskoSigorta"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_weight="1"
android:text="@string/textKaskoSigorta" />
<EditText
android:id="@+id/editTextKaskoSigorta"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_span="3"
android:layout_weight="1"
android:ems="10"
android:hint="@string/ikiyuzyirmibes"
android:inputType="numberDecimal" />
</TableRow>
<TableRow
android:id="@+id/tableRow10"
android:layout_width="match_parent"
android:layout_height="match_parent" >
<LinearLayout
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_weight="10"
android:orientation="horizontal" >
<Spinner
android:id="@+id/spinnerYillar"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_weight="3"
android:entries="@array/Yillar"
android:prompt="@string/promptYillar" />
<Spinner
android:id="@+id/spinnerAylar"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_weight="3"
android:entries="@array/Aylar"
android:prompt="@string/prompt" />
</LinearLayout>
<Button
android:id="@+id/buttonIleri"
style="?android:attr/buttonStyleSmall"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="right"
android:layout_weight="0"
android:background="@drawable/navigation_forward"
android:gravity="right" />
</TableRow>
</TableLayout>
</LinearLayout>
Here is the error log:
!ENTRY com.android.ide.eclipse.adt 4 0 2012-12-25 16:41:18.827
!MESSAGE butcegiris.xml: Index: 1, Size: 1
!STACK 0
java.lang.IndexOutOfBoundsException: Index: 1, Size: 1
at java.util.ArrayList.rangeCheck(Unknown Source)
at java.util.ArrayList.get(Unknown Source)
at com.android.ninepatch.NinePatchChunk.draw(NinePatchChunk.java:174)
at com.android.ninepatch.NinePatchChunk.draw(NinePatchChunk.java:101)
at android.graphics.NinePatch_Delegate$1.draw(NinePatch_Delegate.java:219)
at com.android.layoutlib.bridge.impl.GcSnapshot.drawInLayer(GcSnapshot.java:608)
at com.android.layoutlib.bridge.impl.GcSnapshot.draw(GcSnapshot.java:577)
at android.graphics.NinePatch_Delegate.draw(NinePatch_Delegate.java:217)
at android.graphics.NinePatch_Delegate.nativeDraw(NinePatch_Delegate.java:170)
at android.graphics.NinePatch.nativeDraw(NinePatch.java)
at android.graphics.NinePatch.draw(NinePatch.java:104)
at android.graphics.drawable.NinePatchDrawable.draw(NinePatchDrawable.java:188)
at android.view.View.draw(View.java:6725)
at android.view.ViewGroup.drawChild(ViewGroup.java:1640)
at android.view.ViewGroup.dispatchDraw(ViewGroup.java:1367)
at android.view.View.draw(View.java:6743)
at android.view.ViewGroup.drawChild(ViewGroup.java:1640)
at android.view.ViewGroup.dispatchDraw(ViewGroup.java:1367)
at android.view.View.draw(View.java:6743)
at com.android.layoutlib.bridge.impl.RenderSessionImpl.render(RenderSessionImpl.java:466)
at com.android.layoutlib.bridge.Bridge.createSession(Bridge.java:320)
at com.android.ide.common.rendering.LayoutLibrary.createSession(LayoutLibrary.java:325)
at com.android.ide.eclipse.adt.internal.editors.layout.gle2.RenderService.createRenderSession(RenderService.java:440)
at com.android.ide.eclipse.adt.internal.editors.layout.gle2.GraphicalEditorPart.renderWithBridge(GraphicalEditorPart.java:1545)
at com.android.ide.eclipse.adt.internal.editors.layout.gle2.GraphicalEditorPart.recomputeLayout(GraphicalEditorPart.java:1302)
at com.android.ide.eclipse.adt.internal.editors.layout.gle2.GraphicalEditorPart.changed(GraphicalEditorPart.java:718)
at com.android.ide.eclipse.adt.internal.editors.layout.configuration.ConfigurationChooser.setConfiguration(ConfigurationChooser.java:632)
at com.android.ide.eclipse.adt.internal.editors.layout.gle2.RenderPreviewManager.switchTo(RenderPreviewManager.java:1352)
at com.android.ide.eclipse.adt.internal.editors.layout.gle2.RenderPreview.click(RenderPreview.java:837)
at com.android.ide.eclipse.adt.internal.editors.layout.gle2.RenderPreviewManager.click(RenderPreviewManager.java:1494)
at com.android.ide.eclipse.adt.internal.editors.layout.gle2.GestureManager$Listener.mouseUp(GestureManager.java:469)
at org.eclipse.swt.widgets.TypedListener.handleEvent(TypedListener.java:219)
at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java:84)
at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1053)
at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java:4165)
at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:3754)
at org.eclipse.ui.internal.Workbench.runEventLoop(Workbench.java:2701)
at org.eclipse.ui.internal.Workbench.runUI(Workbench.java:2665)
at org.eclipse.ui.internal.Workbench.access$4(Workbench.java:2499)
at org.eclipse.ui.internal.Workbench$7.run(Workbench.java:679)
at org.eclipse.core.databinding.observable.Realm.runWithDefault(Realm.java:332)
at org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Workbench.java:668)
at org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.java:149)
at org.eclipse.ui.internal.ide.application.IDEApplication.start(IDEApplication.java:123)
at org.eclipse.equinox.internal.app.EclipseAppHandle.run(EclipseAppHandle.java:196)
at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.runApplication(EclipseAppLauncher.java:110)
at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.start(EclipseAppLauncher.java:79)
at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:344)
at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:179)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at org.eclipse.equinox.launcher.Main.invokeFramework(Main.java:622)
at org.eclipse.equinox.launcher.Main.basicRun(Main.java:577)
at org.eclipse.equinox.launcher.Main.run(Main.java:1410)
!ENTRY com.android.ide.eclipse.adt 4 0 2012-12-25 16:41:18.991
!MESSAGE butcegiris.xml: Index: 1, Size: 1
!STACK 0
java.lang.IndexOutOfBoundsException: Index: 1, Size: 1