Come posso liberare dagli errori si sono verificati durante l'esecuzione la mia prima app Android ?

? user3398035 @ | Original: StackOverFlow
---

sto ottenendo gli errori durante l'esecuzione la mia prima app sul dispositivo reale in eclipse.I ' ve abilitato debug USB sul mio dispositivo e premuto " Esegui come" in eclissi poi ho avuto 7 errori

Description Resource    Path    Location    Type
Invalid layout param in a LinearLayout: layout_alignParentTop   abc_action_bar_decor_overlay.xml    /appcompat_v7/res/layout    line 32 Android Lint Problem
Wrong orientation? No orientation specified, and the default is horizontal, yet this layout has multiple children where at least one has layout_width="match_parent"    abc_action_bar_decor_overlay.xml    /appcompat_v7/res/layout    line 25 Android Lint Problem
The following unrelated icon files have identical contents: abc_textfield_search_selected_holo_dark.9.png, abc_textfield_search_selected_holo_light.9.png   abc_textfield_search_selected_holo_light.9.png  /appcompat_v7/res/drawable-mdpi line 1  Android Lint Problem
The resource R.dimen.abc_search_view_preferred_width appears to be unused   dimens.xml  /appcompat_v7/res/values    line 53 Android Lint Problem
The resource R.bool.abc_action_bar_expanded_action_views_exclusive appears to be unused bools.xml   /appcompat_v7/res/values    line 19 Android Lint Problem
The resource R.integer.abc_max_action_buttons appears to be unused  dimens.xml  /appcompat_v7/res/values    line 22 Android Lint Problem
The following unrelated icon files have identical contents: abc_list_pressed_holo_dark.9.png, abc_list_pressed_holo_light.9.png abc_list_pressed_holo_light.9.png   /appcompat_v7/res/drawable-hdpi line 1  Android Lint Problem
The resource R.bool.abc_action_bar_embed_tabs_pre_jb appears to be unused   bools.xml   /appcompat_v7/res/values    line 18 Android Lint Problem
The resource R.dimen.abc_action_bar_stacked_tab_max_width appears to be unused  dimens.xml  /appcompat_v7/res/values    line 27 Android Lint Problem
The resource R.layout.abc_action_bar_tab appears to be unused   abc_action_bar_tab.xml  /appcompat_v7/res/layout    line 1  Android Lint Problem
The resource R.dimen.abc_action_bar_stacked_max_height appears to be unused dimens.xml  /appcompat_v7/res/values    line 44 Android Lint Problem
Nested weights are bad for performance  abc_search_view.xml /appcompat_v7/res/layout    line 90 Android Lint Problem
[Accessibility] Missing contentDescription attribute on image   abc_search_view.xml /appcompat_v7/res/layout    line 64 Android Lint Problem
Use a layout_width of 0dip instead of wrap_content for better performance   abc_search_view.xml /appcompat_v7/res/layout    line 78 Android Lint Problem
The resource R.layout.abc_list_menu_item_icon appears to be unused  abc_list_menu_item_icon.xml /appcompat_v7/res/layout    line 1  Android Lint Problem
The abc_list_divider_holo_dark.9.png icon has identical contents in the following configuration folders: drawable-hdpi, drawable-mdpi   abc_list_divider_holo_dark.9.png    /appcompat_v7/res/drawable-mdpi line 1  Android Lint Problem
Nested weights are bad for performance  abc_search_view.xml /appcompat_v7/res/layout    line 80 Android Lint Problem
Attribute is missing the Android namespace prefix   abc_search_dropdown_dark.xml    /appcompat_v7/res/drawable  line 19 Android Lint Problem
The resource R.anim.abc_fade_out appears to be unused   abc_fade_out.xml    /appcompat_v7/res/anim  line 1  Android Lint Problem
The resource R.layout.abc_action_bar_view_list_nav_layout appears to be unused  abc_action_bar_view_list_nav_layout.xml /appcompat_v7/res/layout    line 1  Android Lint Problem
Use a layout_width of 0dip instead of wrap_content for better performance   abc_search_view.xml /appcompat_v7/res/layout    line 54 Android Lint Problem
The resource R.layout.abc_action_bar_decor appears to be unused abc_action_bar_decor.xml    /appcompat_v7/res/layout    line 1  Android Lint Problem
The resource R.anim.abc_slide_out_top appears to be unused  abc_slide_out_top.xml   /appcompat_v7/res/anim  line 1  Android Lint Problem
The resource R.layout.abc_action_menu_layout appears to be unused   abc_action_menu_layout.xml  /appcompat_v7/res/layout    line 1  Android Lint Problem
The resource R.anim.abc_slide_in_bottom appears to be unused    abc_slide_in_bottom.xml /appcompat_v7/res/anim  line 1  Android Lint Problem
The resource R.layout.abc_action_mode_bar appears to be unused  abc_action_mode_bar.xml /appcompat_v7/res/layout    line 1  Android Lint Problem
The resource R.layout.abc_action_bar_title_item appears to be unused    abc_action_bar_title_item.xml   /appcompat_v7/res/layout    line 1  Android Lint Problem
[Accessibility] Missing contentDescription attribute on image   abc_action_bar_title_item.xml   /appcompat_v7/res/layout    line 25 Android Lint Problem
The following unrelated icon files have identical contents: abc_textfield_search_right_selected_holo_dark.9.png, abc_textfield_search_right_selected_holo_light.9.png   abc_textfield_search_right_selected_holo_light.9.png    /appcompat_v7/res/drawable-xhdpi    line 1  Android Lint Problem
The resource R.layout.abc_expanded_menu_layout appears to be unused abc_expanded_menu_layout.xml    /appcompat_v7/res/layout    line 1  Android Lint Problem
[Accessibility] Missing contentDescription attribute on image   abc_activity_chooser_view_include.xml   /appcompat_v7/res/layout    line 54 Android Lint Problem
Duplicate id @+id/image, already defined earlier in this layout abc_activity_chooser_view_include.xml   /appcompat_v7/res/layout    line 55 Android Lint Problem
[Accessibility] Missing contentDescription attribute on image   abc_activity_chooser_view_include.xml   /appcompat_v7/res/layout    line 31 Android Lint Problem
"action_settings" is not translated in af, am, ar, bg, ca, cs, da, de, el, en-rGB, en-rIN, es, es-rUS, et-rEE, fa, fi, fr, fr-rCA, hi, hr, hu, hy-rAM, in, it, iw, ja, ka-rGE, km-rKH, ko, lo-rLA, lt, lv, mn-rMN, ms-rMY, nb, nl, pl, pt, pt-rPT, ro, ru, sk, sl, sr, sv, sw, th, tl, tr, uk, vi, zh-rCN, zh-rHK, zh-rTW, zu   strings.xml /MyFirstApp/res/values  line 5  Android Lint Problem
The following unrelated icon files have identical contents: abc_textfield_search_right_selected_holo_dark.9.png, abc_textfield_search_right_selected_holo_light.9.png   abc_textfield_search_right_selected_holo_light.9.png    /appcompat_v7/res/drawable-mdpi line 1  Android Lint Problem
"app_name" is not translated in af, am, ar, bg, ca, cs, da, de, el, en-rGB, en-rIN, es, es-rUS, et-rEE, fa, fi, fr, fr-rCA, hi, hr, hu, hy-rAM, in, it, iw, ja, ka-rGE, km-rKH, ko, lo-rLA, lt, lv, mn-rMN, ms-rMY, nb, nl, pl, pt, pt-rPT, ro, ru, sk, sl, sr, sv, sw, th, tl, tr, uk, vi, zh-rCN, zh-rHK, zh-rTW, zu  strings.xml /MyFirstApp/res/values  line 4  Android Lint Problem
"hello_world" is not translated in af, am, ar, bg, ca, cs, da, de, el, en-rGB, en-rIN, es, es-rUS, et-rEE, fa, fi, fr, fr-rCA, hi, hr, hu, hy-rAM, in, it, iw, ja, ka-rGE, km-rKH, ko, lo-rLA, lt, lv, mn-rMN, ms-rMY, nb, nl, pl, pt, pt-rPT, ro, ru, sk, sl, sr, sv, sw, th, tl, tr, uk, vi, zh-rCN, zh-rHK, zh-rTW, zu   strings.xml /MyFirstApp/res/values  line 6  Android Lint Problem
Attribute is missing the Android namespace prefix   abc_search_dropdown_light.xml   /appcompat_v7/res/drawable  line 19 Android Lint Problem
This tag and its children can be replaced by one <TextView/> and a compound drawable    abc_activity_chooser_view_list_item.xml /appcompat_v7/res/layout    line 26 Android Lint Problem
This LinearLayout layout or its LinearLayout parent is useless  abc_activity_chooser_view_list_item.xml /appcompat_v7/res/layout    line 26 Android Lint Problem
The resource R.layout.abc_popup_menu_item_layout appears to be unused   abc_popup_menu_item_layout.xml  /appcompat_v7/res/layout    line 1  Android Lint Problem
The resource R.layout.abc_activity_chooser_view_list_item appears to be unused  abc_activity_chooser_view_list_item.xml /appcompat_v7/res/layout    line 1  Android Lint Problem
[Accessibility] Missing contentDescription attribute on image   abc_activity_chooser_view_list_item.xml /appcompat_v7/res/layout    line 31 Android Lint Problem
The resource R.layout.abc_activity_chooser_view appears to be unused    abc_activity_chooser_view.xml   /appcompat_v7/res/layout    line 1  Android Lint Problem
The resource R.layout.abc_search_dropdown_item_icons_2line appears to be unused abc_search_dropdown_item_icons_2line.xml    /appcompat_v7/res/layout    line 1  Android Lint Problem
The following unrelated icon files have identical contents: abc_list_pressed_holo_dark.9.png, abc_list_pressed_holo_light.9.png abc_list_pressed_holo_light.9.png   /appcompat_v7/res/drawable-xhdpi    line 1  Android Lint Problem
[Accessibility] Missing contentDescription attribute on image   abc_action_mode_close_item.xml  /appcompat_v7/res/layout    line 27 Android Lint Problem
The resource R.layout.abc_action_mode_close_item appears to be unused   abc_action_mode_close_item.xml  /appcompat_v7/res/layout    line 1  Android Lint Problem
[Accessibility] Missing contentDescription attribute on image   abc_search_dropdown_item_icons_2line.xml    /appcompat_v7/res/layout    line 49 Android Lint Problem
[Accessibility] Missing contentDescription attribute on image   abc_search_dropdown_item_icons_2line.xml    /appcompat_v7/res/layout    line 29 Android Lint Problem
[Accessibility] Missing contentDescription attribute on image   abc_search_dropdown_item_icons_2line.xml    /appcompat_v7/res/layout    line 38 Android Lint Problem
The resource R.layout.abc_action_bar_decor_overlay appears to be unused abc_action_bar_decor_overlay.xml    /appcompat_v7/res/layout    line 1  Android Lint Problem
The resource R.layout.abc_search_view appears to be unused  abc_search_view.xml /appcompat_v7/res/layout    line 1  Android Lint Problem
The following unrelated icon files have identical contents: abc_list_pressed_holo_dark.9.png, abc_list_pressed_holo_light.9.png abc_list_pressed_holo_light.9.png   /appcompat_v7/res/drawable-mdpi line 1  Android Lint Problem
Possible overdraw: Root element paints background ?attr/actionBarItemBackground with a theme that also paints a background (inferred theme is @style/AppTheme)  abc_action_bar_home.xml /appcompat_v7/res/layout    line 21 Android Lint Problem
The resource R.dimen.abc_config_prefDialogWidth appears to be unused    config.xml  /appcompat_v7/res/values    line 28 Android Lint Problem
The resource R.layout.abc_list_menu_item_checkbox appears to be unused  abc_list_menu_item_checkbox.xml /appcompat_v7/res/layout    line 1  Android Lint Problem
The resource R.anim.abc_slide_out_bottom appears to be unused   abc_slide_out_bottom.xml    /appcompat_v7/res/anim  line 1  Android Lint Problem
The resource R.layout.support_simple_spinner_dropdown_item appears to be unused support_simple_spinner_dropdown_item.xml    /appcompat_v7/res/layout    line 1  Android Lint Problem
The abc_list_divider_holo_light.9.png icon has identical contents in the following configuration folders: drawable-hdpi, drawable-mdpi  abc_list_divider_holo_light.9.png   /appcompat_v7/res/drawable-mdpi line 1  Android Lint Problem
The resource R.bool.abc_config_allowActionMenuItemTextWithIcon appears to be unused config.xml  /appcompat_v7/res/values    line 23 Android Lint Problem
[Accessibility] Missing contentDescription attribute on image   abc_list_menu_item_icon.xml /appcompat_v7/res/layout    line 17 Android Lint Problem
The resource R.layout.abc_list_menu_item_radio appears to be unused abc_list_menu_item_radio.xml    /appcompat_v7/res/layout    line 1  Android Lint Problem
The resource R.layout.abc_action_menu_item_layout appears to be unused  abc_action_menu_item_layout.xml /appcompat_v7/res/layout    line 1  Android Lint Problem
The resource R.layout.abc_list_menu_item_layout appears to be unused    abc_list_menu_item_layout.xml   /appcompat_v7/res/layout    line 1  Android Lint Problem
This class should be public (android.support.v7.internal.widget.ActionBarView.HomeView) MyFirstApp      line 1  Android Lint Problem
The resource R.anim.abc_fade_in appears to be unused    abc_fade_in.xml /appcompat_v7/res/anim  line 1  Android Lint Problem
The resource R.string.abc_shareactionprovider_share_with appears to be unused   strings.xml /appcompat_v7/res/values    line 46 Android Lint Problem
The resource R.string.abc_activitychooserview_choose_application appears to be unused   strings.xml /appcompat_v7/res/values    line 40 Android Lint Problem
Missing the following drawables in drawable-xhdpi: abc_ic_clear_normal.png (found in drawable-hdpi, drawable-mdpi)  MyFirstApp      line 1  Android Lint Problem
The resource R.anim.abc_slide_in_top appears to be unused   abc_slide_in_top.xml    /appcompat_v7/res/anim  line 1  Android Lint Problem
The resource R.string.abc_shareactionprovider_share_with_application appears to be unused   strings.xml /appcompat_v7/res/values    line 44 Android Lint Problem
[Accessibility] Missing contentDescription attribute on image   abc_action_bar_decor_overlay.xml    /appcompat_v7/res/layout    line 47 Android Lint Problem
The resource R.bool.abc_config_showMenuShortcutsWhenKeyboardPresent appears to be unused    bools.xml   /appcompat_v7/res/values    line 22 Android Lint Problem
[Accessibility] Missing contentDescription attribute on image   abc_action_bar_home.xml /appcompat_v7/res/layout    line 22 Android Lint Problem
The resource R.bool.abc_split_action_bar_is_narrow appears to be unused bools.xml   /appcompat_v7/res/values    line 20 Android Lint Problem
The resource R.layout.abc_action_bar_tabbar appears to be unused    abc_action_bar_tabbar.xml   /appcompat_v7/res/layout    line 1  Android Lint Problem
[Accessibility] Missing contentDescription attribute on image   abc_action_bar_home.xml /appcompat_v7/res/layout    line 29 Android Lint Problem
The resource R.string.abc_action_bar_up_description appears to be unused    strings.xml /appcompat_v7/res/values    line 23 Android Lint Problem
The resource R.string.abc_action_bar_home_description appears to be unused  strings.xml /appcompat_v7/res/values    line 21 Android Lint Problem
The resource R.string.abc_activity_chooser_view_see_all appears to be unused    strings.xml /appcompat_v7/res/values    line 42 Android Lint Problem
The resource R.string.abc_action_menu_overflow_description appears to be unused strings.xml /appcompat_v7/res/values    line 25 Android Lint Problem
---

Top 5 Risposta

1aprados @

Sembra che si è scelto di creare un progetto di API 10 compatibile ( appcompat_v7 nel registro ) .

Assicurarsi che Eclipse crea due cartelle nella struttura di progetto ( nameofyourproject e appcompat_v7 ) . Se appcompat_v7 esiste, è sufficiente selezionare le proprietà ( tasto destro nella cartella nameofyourproject / proprietà ), poi per Android e infine aggiungere appcompat_v7 progetto .

Pulire il bild ( progetto / pulito) e ... dovrebbe essere ok .

Se questo non funziona, si prega di verificare Finestra / Android SDK Manager ( installare tutti i pacchetti necessari ) .

Good luck!

2Ewoks @

La maggior parte degli errori qui provengono dal Lint .. Essi non rompere l'app ma questi sono errori che si dovrebbe correggere prima del rilascio . Se si desidera eseguire app nonostante tali errori, spegnere Lint spuntare per il progetto per un momento, ma non dimenticate di risolvere questi problemi . Clean progetto rimuoverà segnalato errori Lint .