It's been a whole day of eclipse crying. Also blame oneself hand cheap appcompat_v7 to delete.
Eclipse creation Project assumes compatibility with 4.0 below and generates more than one projectappcompat_v7, for example:
This project will be referenced to your target project as a compatibility package and cannot be deleted.
If you delete it, the R file cannot be generated. I ran out of hundreds of mistakes.
The properties->android of project right will become, for example, a red fork:
Workaround:
1, if you delete appcompat_v7, did not choose this
。
Then go to the hard drive and delete the appcompat_v7 completely.
2, create a new project in the workspace, compatible with the minimum version number remains the same, so that the workspace will generate a appcompat_v7;
3, the original project right button properties->android, remove the Red fork, add one. The results are as follows:
Android Eclipse can't generate R file