I used a style file to set a unique style for same layouts,
Style:
<resources xmlns:android="http://schemas.android.com/apk/res/android">
<!-- User form layout style -->
<style name="UserFormLayoutRow">
<item name="android:layout_width">match_parent</item>
<item name="android:layout_height">wrap_content</item>
<item name="android:orientation">horizontal</item>
<item name="android:paddingBottom">@dimen/padding_small</item>
</style>
</resources >
//In layout file
<LinearLayout
style="@style/UserFormLayoutRow" >
//contents
</LinearLayout>
Error:(design time)
Error at run time:
06-13 05:58:14.506: E/AndroidRuntime(936): Caused by: java.lang.RuntimeException: Binary XML file line #105: You must supply a layout_width attribute.
Where i am going wrong? TIA
res\values
folder, but not in thevalues-v11
andvalues-v14
folders? You might try to define them in those 2 folders as well according to this question. – BorkowskiLinearLayout
close tag missing,//
is not a valid comment for xml,xmlns:android
is not needed forvalues
resources. So, since what you posted works for others, there's something missing from the question. – Pleader