Sunday, November 27, 2011

AndroidManifest.xml has the error "No resource found that matches the given name (at 'icon' with value '@drawable/icon')." for the application tag.

AndroidManifest.xml has the error "No resource found that matches the given name (at 'icon' with value '@drawable/icon')." for the application tag (highlighted in red color below)

<application
 android:icon="@drawable/icon"
android:label="@string/app_name" >
<activity
android:label="@string/app_name"
android:name=".FirstAppsActivity" >
<intent-filter >
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
</application>

I have faced the issue for multiple times. I have found 2 reasons for this error.
1) icon.png is not present in the drawable-hdpi folder inside res folder of Android project.
2) Android application is not able to find the icon.png file.

Solution

1) Make sure that icon.png (or whatever files mentioned in the <application android:icon tag) is present in the drawable-hdpi folder inside res folder of Android project.

2)If it shows the error even if the icon.png is present,then remove the statement <application android:icon from the AndroidManifest.xml and add it again.

Saturday, November 12, 2011

Why Java script changes made are not reflecting in the output? OR Java script changes are working in the local machine but not reflecting when application is deployed in the server

It is a common problem faced by most of the web application developers.
Reason is java script files(.js files) are cached in the local machine to improve the performance of the system.So web application is referring to the stored version of the java script file.

Solution
Clear the browser cache,temporary internet files and run the application again.
In IE,Go to Tools -> Internet Options->Temporary Internet files ->Click on settings
Set Check for newer versions of the stored pages to Every visit to the pages.

If the application has the configuration file for the cache timeouts ,change the configurations to decrease the cache timeout for java script.

Resolve "Target runtime Apache Tomcat v6.0 is not defined." error

Go to window ->preferences ->Server->Runtime environments . add server Apache Tomcat v6.0 Mention the directory where apache-toma...