Eclipse doesn't create Main Activity and layout

前端 未结 7 1814
小鲜肉
小鲜肉 2020-12-05 16:34

I can\'t start new projects anymore. This is what I do...

  • Start Eclipse.
  • New Android Application
    • min API 8
    • target <
相关标签:
7条回答
  • 2020-12-05 16:54

    I had the same problem yesterday after updating the latest packages on the Android SDK Manager.

    Fixed it by updating the Eclipse plugin: Run Eclipse > Help > Install new software > Paste the URL https://dl-ssl.google.com/android/eclipse/ then press Enter. After updating the plugin, I created a test project with the main activity and menu was created by default as normal.

    0 讨论(0)
  • 2020-12-05 16:54

    I have the same problem before.

    Using this Eclipse Update http://dl-ssl.google.com/android/eclipse/ did not work for me. I notice this problem when I download the latest updated SDK

    enter image description here

    Luckily the solution to my problem is very easy. enter image description here

    By Selecting Empty Project instead of Blank Activity makes it working.

    0 讨论(0)
  • 2020-12-05 16:55

    I had the same problema also. I fixed the problem follow the Werner recomendation. Eclipse --> Help --> Install new software --> Pasted URL http://dl-ssl.google.com/android/eclipse/ pressed Enter, but It's important check it out and remove before any copy of the plugin installed in available Software Sites.

    0 讨论(0)
  • 2020-12-05 17:05

    I had a problem with opening the layout folder. I needed a xml file with the contents as below:

    <?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:orientation="horizontal" >
    </LinearLayout>
    

    So,this is what I did.I tried updating eclipse but, the problem persisted. So,I just created a new xml file by right-clicking the layout folder.After creating the file,I just copy-pasted the aforementioned content.Hope it helps!

    0 讨论(0)
  • 2020-12-05 17:08

    It happened to me too. It suddenly stopped creating MainActivity.java and layout. I could fix it by updating Eclipse:
    Help -> Check for updates -> Select all

    0 讨论(0)
  • 2020-12-05 17:10

    I had the same problem also. I fixed the problem follow the Werner recomendation. Eclipse --> Help --> Install new software --> Pasted URL http://dl-ssl.google.com/android/eclipse/ It fixed my problem.

    0 讨论(0)
提交回复
热议问题