<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic If you app is stopped as soon in Software Archive</title>
    <link>https://community.intel.com/t5/Software-Archive/Unfotunately-app-has-stopped/m-p/1029283#M41384</link>
    <description>&lt;P&gt;If you app is stopped as soon as it is started, then the problem is likely in the code executed inside OnCreate().&lt;/P&gt;

&lt;P&gt;Excluding code inside listeners, because it is not executed, there are just two rows of code that should cause a forced stop for NullPointerException: the two rows where you set listener for &lt;STRONG&gt;add&lt;/STRONG&gt; and &lt;STRONG&gt;sub &lt;/STRONG&gt;buttons. My guess is that &lt;STRONG&gt;IDs &lt;/STRONG&gt;of at least one Button is not button1 or button2 (check you XML layout).&lt;/P&gt;</description>
    <pubDate>Tue, 03 Jun 2014 17:34:22 GMT</pubDate>
    <dc:creator>Bradipao</dc:creator>
    <dc:date>2014-06-03T17:34:22Z</dc:date>
    <item>
      <title>Unfotunately, app has stopped</title>
      <link>https://community.intel.com/t5/Software-Archive/Unfotunately-app-has-stopped/m-p/1029280#M41381</link>
      <description>&lt;P&gt;package com.example.qao;&lt;/P&gt;

&lt;P&gt;import android.support.v7.app.ActionBarActivity;&lt;BR /&gt;
	import android.os.Bundle;&lt;BR /&gt;
	import android.view.View;&lt;BR /&gt;
	import android.widget.Button;&lt;BR /&gt;
	import android.widget.TextView;&lt;/P&gt;

&lt;P&gt;&lt;BR /&gt;
	public class Main extends ActionBarActivity {&lt;BR /&gt;
	&amp;nbsp;&amp;nbsp; &amp;nbsp; int counter;&amp;nbsp;&lt;BR /&gt;
	&amp;nbsp; &amp;nbsp; &amp;nbsp;Button add, sub;&lt;BR /&gt;
	&amp;nbsp; &amp;nbsp; &amp;nbsp;TextView display;&lt;BR /&gt;
	&amp;nbsp;&amp;nbsp; &amp;nbsp;@Override&lt;BR /&gt;
	&amp;nbsp;&amp;nbsp; &amp;nbsp;protected void onCreate(Bundle savedInstanceState) {&lt;BR /&gt;
	&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;super.onCreate(savedInstanceState);&lt;BR /&gt;
	&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;setContentView(R.layout.activity_main);&lt;BR /&gt;
	&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&lt;BR /&gt;
	&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;counter=0;&lt;BR /&gt;
	&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;add= (Button)findViewById(R.id.button1);&lt;BR /&gt;
	&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;sub= (Button)findViewById(R.id.button2);&lt;BR /&gt;
	&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;display=(TextView)findViewById(R.id.textView1);&lt;BR /&gt;
	&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;add.setOnClickListener(new View.OnClickListener() {&lt;BR /&gt;
	&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&lt;BR /&gt;
	&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;@Override&lt;BR /&gt;
	&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;public void onClick(View v) {&lt;BR /&gt;
	&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;// TODO Auto-generated method stub&lt;BR /&gt;
	&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;counter++;&lt;BR /&gt;
	&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;display.setText("Your Total Is "+ counter);&lt;BR /&gt;
	&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;}&lt;BR /&gt;
	&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;} );&lt;BR /&gt;
	&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;sub.setOnClickListener(new View.OnClickListener() {&lt;BR /&gt;
	&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&lt;BR /&gt;
	&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;@Override&lt;BR /&gt;
	&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;public void onClick(View v) {&lt;BR /&gt;
	&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;// TODO Auto-generated method stub&lt;BR /&gt;
	&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;counter--;&lt;BR /&gt;
	&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;display.setText("Your Total Is " +counter);&lt;BR /&gt;
	&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;}&lt;BR /&gt;
	&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;});&lt;BR /&gt;
	&amp;nbsp;&amp;nbsp; &amp;nbsp;}&amp;nbsp;&lt;/P&gt;

&lt;P&gt;}&lt;/P&gt;

&lt;P&gt;this is my program it shows no error on eclipse but when i run the program emulator doesn't run it emulator shows a message "unfortunately app has stopped" someone please find the mistake in it. I just started learning android development but now i am stuck with that problem.&amp;nbsp;&lt;BR /&gt;
	&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sun, 01 Jun 2014 02:45:32 GMT</pubDate>
      <guid>https://community.intel.com/t5/Software-Archive/Unfotunately-app-has-stopped/m-p/1029280#M41381</guid>
      <dc:creator>Farhan_I_</dc:creator>
      <dc:date>2014-06-01T02:45:32Z</dc:date>
    </item>
    <item>
      <title>Hello,</title>
      <link>https://community.intel.com/t5/Software-Archive/Unfotunately-app-has-stopped/m-p/1029281#M41382</link>
      <description>&lt;P&gt;Hello,&lt;/P&gt;

&lt;P&gt;Could you add log information? You can find it using the Eclipse with logcat or, before run the app while the emulator is running, type in the terminal:&lt;BR /&gt;
	$&amp;gt; adb shell logcat&lt;/P&gt;

&lt;P&gt;Copy and paste the error message and the exception stack information in the forum, so it can be easier to debug.&lt;/P&gt;

&lt;P&gt;Looks like a NullPointerException somewhere in your code, the log information will help you.&lt;/P&gt;</description>
      <pubDate>Mon, 02 Jun 2014 20:17:29 GMT</pubDate>
      <guid>https://community.intel.com/t5/Software-Archive/Unfotunately-app-has-stopped/m-p/1029281#M41382</guid>
      <dc:creator>George_Silva_Intel</dc:creator>
      <dc:date>2014-06-02T20:17:29Z</dc:date>
    </item>
    <item>
      <title>If you don't know how to get</title>
      <link>https://community.intel.com/t5/Software-Archive/Unfotunately-app-has-stopped/m-p/1029282#M41383</link>
      <description>&lt;P&gt;If you don't know how to get the logcat output you can also simply zip your full project and attach it to a message.&amp;nbsp;&lt;/P&gt;

&lt;P&gt;The code you attached looks correct. So I guess that add or sub is null because you Changed something in the layout file.&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 03 Jun 2014 09:54:27 GMT</pubDate>
      <guid>https://community.intel.com/t5/Software-Archive/Unfotunately-app-has-stopped/m-p/1029282#M41383</guid>
      <dc:creator>Alexander_W_Intel</dc:creator>
      <dc:date>2014-06-03T09:54:27Z</dc:date>
    </item>
    <item>
      <title>If you app is stopped as soon</title>
      <link>https://community.intel.com/t5/Software-Archive/Unfotunately-app-has-stopped/m-p/1029283#M41384</link>
      <description>&lt;P&gt;If you app is stopped as soon as it is started, then the problem is likely in the code executed inside OnCreate().&lt;/P&gt;

&lt;P&gt;Excluding code inside listeners, because it is not executed, there are just two rows of code that should cause a forced stop for NullPointerException: the two rows where you set listener for &lt;STRONG&gt;add&lt;/STRONG&gt; and &lt;STRONG&gt;sub &lt;/STRONG&gt;buttons. My guess is that &lt;STRONG&gt;IDs &lt;/STRONG&gt;of at least one Button is not button1 or button2 (check you XML layout).&lt;/P&gt;</description>
      <pubDate>Tue, 03 Jun 2014 17:34:22 GMT</pubDate>
      <guid>https://community.intel.com/t5/Software-Archive/Unfotunately-app-has-stopped/m-p/1029283#M41384</guid>
      <dc:creator>Bradipao</dc:creator>
      <dc:date>2014-06-03T17:34:22Z</dc:date>
    </item>
    <item>
      <title>Thanks all of you!</title>
      <link>https://community.intel.com/t5/Software-Archive/Unfotunately-app-has-stopped/m-p/1029284#M41385</link>
      <description>&lt;P&gt;Thanks all of you!&lt;/P&gt;

&lt;P&gt;I really appreciate your help. I just started learning android development.&lt;/P&gt;

&lt;P&gt;here it takes too long to get a reply. If you can give me your email. i can share my problem with you on your email address directly.&lt;/P&gt;

&lt;P&gt;here is mine farhanijaz03@gmail.com if you want to give your email address just send me a mail.&lt;/P&gt;

&lt;P&gt;thanks for your help&lt;/P&gt;</description>
      <pubDate>Tue, 03 Jun 2014 18:18:55 GMT</pubDate>
      <guid>https://community.intel.com/t5/Software-Archive/Unfotunately-app-has-stopped/m-p/1029284#M41385</guid>
      <dc:creator>Farhan_I_</dc:creator>
      <dc:date>2014-06-03T18:18:55Z</dc:date>
    </item>
    <item>
      <title>To solve this kind of</title>
      <link>https://community.intel.com/t5/Software-Archive/Unfotunately-app-has-stopped/m-p/1029285#M41386</link>
      <description>&lt;P&gt;To solve this kind of problems is very important to post the messages displayed in LogCat, otherwise is very difficult to get a solution :(.&lt;/P&gt;

&lt;P&gt;for my experience if you have the message: "&lt;SPAN style="font-size: 12px; line-height: 18px;"&gt;"unfortunately app has stopped" the two main causes are:&lt;/SPAN&gt;&lt;/P&gt;

&lt;P&gt;&lt;SPAN style="font-size: 12px; line-height: 18px;"&gt;1) any of this elements:&lt;/SPAN&gt;&lt;/P&gt;

&lt;PRE class="brush:java;"&gt;        add= (Button)findViewById(R.id.button1);
        sub= (Button)findViewById(R.id.button2);
        display=(TextView)findViewById(R.id.textView1);&lt;/PRE&gt;

&lt;P&gt;doesn´t exist inside the layout: "activity_main.xml"&lt;/P&gt;

&lt;P&gt;2) &amp;nbsp;probably your activity is not registered inside the "AndroidManifest.xml".&lt;/P&gt;

&lt;P&gt;&amp;nbsp;&lt;/P&gt;

&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 24 Sep 2014 21:48:45 GMT</pubDate>
      <guid>https://community.intel.com/t5/Software-Archive/Unfotunately-app-has-stopped/m-p/1029285#M41386</guid>
      <dc:creator>Jorgesys</dc:creator>
      <dc:date>2014-09-24T21:48:45Z</dc:date>
    </item>
  </channel>
</rss>

