-
Notifications
You must be signed in to change notification settings - Fork 63
Open
Description
Hi.
I'm trying to add item in a for loop, But it has error :" Binary XML file line #13: You must supply a layout_width attribute. "
I'm using this code in onCreate() method:
List<ParseObject> list = null;
try {
list = query.find();
} catch (ParseException e) {
e.printStackTrace();
}
for (int i = 0; i < list.size(); i++) {
addItem(new SwitcherItem(getApplication(), String.valueOf(i)).setTitle(list.get(i).getString("title")));
}
The list has 6 items.
I also added them to activity
<activity
android:name=".Activity.SettingActivity"
android:label="@string/title_activity_setting"
android:theme="@style/MaterialSettingsTheme">
</activity>
Metadata
Metadata
Assignees
Labels
No labels