Why Android R.java file can be in src/ or gen/?

Tags: xml android

When i started learning android i learned that R.java files goes to /gen folder

recently i saw it on /src file

( in WROX-Professional Android App Dev- sample code downloads ).

How does this work.

and also in some code i saw ( xml layout )

android:id="@+id/R.id.someName" ( i don't remember in which web page i saw this code , sorry ).

I don't understand this, can somebody help me with this.

Thanks in advance.


In older versions of Android (prior to 1.5), R.java was located in src/. It's not anymore it you should keep your's in gen/.

About the id, this is a very easy to answer question et let me think you didn't bother to read Android tutorials. You have the answer here, step 5.

By : e-satis

This video can help you solving your question :)
By: admin