• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Liutauras Vilda
  • Bear Bibeault
  • Jeanne Boyarsky
  • Tim Cooke
Sheriffs:
  • Knute Snortum
  • Junilu Lacar
  • Devaka Cooray
Saloon Keepers:
  • Ganesh Patekar
  • Tim Moores
  • Carey Brown
  • Stephan van Hulst
  • salvin francis
Bartenders:
  • Ron McLeod
  • Frits Walraven
  • Pete Letkeman

Eclipse Android Programming/Buttons  RSS feed

 
Greenhorn
Posts: 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

**Android Manifest**






That up there is my code. When ever I click the button that code is linked to. my app just crashes. I am very new to android programming so if someone could help me out in simple terms, that would be great


Thanks!
 
Bartender
Posts: 2075
276
Android Angular Framework Eclipse IDE Java Linux MySQL Database Redhat TypeScript
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
What are you expecting to happen when you click the button widget?
 
Bartender
Posts: 4179
22
IntelliJ IDE Java Python
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Chung,

Welcome to the Ranch!

I don't see anything wrong with the code you posted, but it isn't complete. You need to use LogCat to find out what exception or error is happening that causes the crash. If you are using an IDE then there should be a view for LogCat, and if not there is an ADB command to view it.

Also, in the future, please UseCodeTags (<- read link for how), it makes the code easier to read.
 
Ron McLeod
Bartender
Posts: 2075
276
Android Angular Framework Eclipse IDE Java Linux MySQL Database Redhat TypeScript
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

Ron McLeod wrote:What are you expecting to happen when you click the button widget?


The reason I asked this question was, after fixing the errors, the behaviour will be that the each time the button is clicked, another instance of the same Activity will be created and placed on the top of the back stack. This is something you wouldn't normally want to do.
 
It is sorta covered in the JavaRanch Style Guide.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!