0

Added new activity via: Best way to add Activity to an Android project in Eclipse?

Soon the new activity added in AndroidManifest.xml is gone?

How do I fix this?

Thank You.

Community
  • 1
  • 1
Greg McNulty
  • 1,476
  • 5
  • 28
  • 50
  • 1
    I had the same problem a while back. I just re-added the activity into the manifest and it was fine. I'm not sure whether there is a legitimate reason for this or whether it is a bug. – edwoollard Oct 28 '12 at 21:45
  • @edwoollard: this is the 3rd time I added it back...guess do a restart of the IDE? – Greg McNulty Oct 28 '12 at 21:46
  • 1
    normally running the emulator shouldnt change anything on manifest file.. are you on eclipse juno and latest ADT? – Paschalis Oct 28 '12 at 21:47
  • @Paschalis: yeah, not sure if it a result of the emulator, I think it is also happening after any other code changes. – Greg McNulty Oct 28 '12 at 21:48
  • @Paschalis: not sure about the "Juno". I am running Eclipse with the android plug in: Eclipse Java EE IDE for Web Developers. Version: Indigo Service Release 2 Build id: 20120216-1857 – Greg McNulty Oct 28 '12 at 21:50
  • 1
    Juno is the latest version of Eclipse, Indigo is before that and is what you have. Just to clarify that for you, Greg. – edwoollard Oct 28 '12 at 21:52
  • @edwoollard: thanks, newbie here – Greg McNulty Oct 28 '12 at 21:52
  • so try updating your eclipse, and your ADT. ADT for eclipse was buggy, and may still is. You can always edit manifest xml file directly from XML code! – Paschalis Oct 29 '12 at 02:50

1 Answers1

1

What OS are you using? this happened with me while am using Mac OS, the AndroidManifest.xml was Read only, so I needed to change it to Read/Write

Mohammad Ersan
  • 12,304
  • 8
  • 54
  • 77