Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Project has no project.properties file

I am developing Android app in Eclipse.

Currently, eclipse complains:

"Project has no project.properties file! Edit the project properties to set one."

But I do have project.properties file under my project root folder. Why it complains?

This problem causes several of the resources in R.java can not be resolved in Activity. How to get rid of this problem?

like image 977
Leem.fin Avatar asked Mar 02 '12 12:03

Leem.fin


People also ask

Where can I find project properties?

You access project properties by right-clicking the project node in Solution Explorer and choosing Properties, or by typing properties into the search box on the menu bar and choosing Properties Window from the results.

Where is project properties in Android Studio?

You can create this file manually in project root directory, near other ". properties" files.

Where is project properties in Eclipse?

To view or edit a project's properties, right-click the project node and select Properties. In the resulting window, you can view and customize the project properties. See the following topics: "Projects"

What are project properties?

Project properties are an advanced mechanism for modifying the behavior of a project that contains Mathematica material. They can be set on any type of project. This is useful because they allow mixed types of projects that contain Mathematica and other languages such as Java.


3 Answers

Right click on project -->Android Tools-->Fix Project Properties.....
like image 74
Samir Mangroliya Avatar answered Nov 15 '22 18:11

Samir Mangroliya


Sometime the 'Fix Project properties...' is not useful. I suggest that you can open that file and edit+save it, then delete the 'project.properties' file. At last you can create a new 'project.properties' file and paste the content of the old 'project.properties' file's content.

That worked for me.

like image 24
Enli Avatar answered Nov 15 '22 17:11

Enli


The accepted answer may had the problem solved a few years ago but it doesn't work anymore with the more recent tools.

This is a known bug on Eclipse.

The only way to solve this problem is by creating again a project.properties file, which no one posted how it looks inside so I'll be posting this as an answer:

# This file is automatically generated by Android Tools.
# Do not modify this file -- YOUR CHANGES WILL BE ERASED!
#
# This file must be checked in Version Control Systems.
#
# To customize properties used by the Ant build system edit
# "ant.properties", and override values to adapt the script to your
# project structure.
#
# To enable ProGuard to shrink and obfuscate your code, uncomment this (available properties: sdk.dir, user.home):
#proguard.config=${sdk.dir}/tools/proguard/proguard-android.txt:proguard-project.txt

# Project target.
target=android-19

Please note: set the correct target API for your project.

like image 32
Machado Avatar answered Nov 15 '22 17:11

Machado