It won't rebuild unless you fix the error first. The error that is causing the R file to not be updated. Once you fix the error, the R file will automatically be generated.
It might be a pain, but keep trying to solve it. If you have to (as a last resort, and the above ideas don't work), remove most of the code from the XML file, and comment out references in your java project files until R updates. Then add components one at a time until it doesn't update, then you know where the problem is. Best of luck. On Feb 3, 4:52 pm, Ashwani Rao <[email protected]> wrote: > Hi Mark, > > Thanks for the idea. > I took the backupp of the R.java file and then did the build through > eclipse(Project -> build project) but the new file was not generated. > > Then i tried through the aapt tool. I got the following error. > > ->aapt c -M /bmc/test/workspace/CatchMe/AndroidManifest.xml -J > /bmc/test/workspace/CatchMe/src/Parry/com/src -A > /bmc/test/workspace/CatchMe/assets -S /bmc/test/workspace/CatchMe/res > (skipping backup file > '/bmc/test/workspace/CatchMeHarry/res/layout/main.xml~') > /bmc/test/workspace/CatchMeHarry/res/layout/main.xml:3: No resource > identifier found for attribute 'orientation' in package 'android' > > Any Idea on the above. > > Reagrds, > Ashwani > On 2/2/09, Mark Roberts <[email protected]> wrote: > > > > > You can force a rebuild by deleting the R.java file > > > On Feb 2, 7:40 am, Ashwani Rao <[email protected]> wrote: > > > Hi, > > > > There is no problem with the backgorund. > > > I am also not getting red line in my xml files. > > > > Should i run the aapt tool from command line ? > > > > Regards, > > > Ashwani > > > > On 2/2/09, madcoder <[email protected]> wrote: > > > > > <LinearLayout android:orientation="vertical" > > > > android:layout_width="fill_parent" android:layout_height="fill_parent" > > > > android:layout_gravity="left" android:background="@drawable/ > > > > background"> > > > > <Button id="@+id/startgame" android:layout_width="fill_parent" > > > > android:layout_height="wrap_content" android:text="New Match" > > > > android:layout_gravity="left"/> > > > > <Button id="@+id/resumegame" android:layout_width="fill_parent" > > > > android:layout_height="wrap_content" android:text="Resume Match" > > > > android:layout_gravity="left"/> > > > > <Button android:id="@+id/demonstration" > > > > android:layout_width="fill_parent" > > > > android:layout_height="wrap_content" android:text="Demo Match" > > > > android:layout_gravity="left"/> > > > > <Button android:id="@+id/instructions" > > > > android:layout_width="fill_parent" > > > > android:layout_height="wrap_content" android:text="Instructions" > > > > android:layout_gravity="left"/> > > > > </LinearLayout> > > > > > Try to add > > > > > android: > > > > > To the First two button id's. > > > > > Are you getting any red squiggly lines anywhere in the xml file? Are > > > > you sure that 'background' has been imported properly into your > > > > project? > > > > > On Feb 2, 2:17 pm, Ashwani Rao <[email protected]> wrote: > > > > > Hi, > > > > > > Please find the attached xml file. > > > > > I am using eclipse and tried to build the project through eclipes > > only. > > > > > > Thanks and Regrads, > > > > > Ashwani > > > > > > On 2/1/09, Kevin J. Brooks <[email protected]> wrote: > > > > > > > This fixed my problem. Try building your project. > > > > > > > On Fri, 2009-01-30 at 07:57 -0500, Mark Murphy wrote: > > > > > > > Ashwani Rao wrote: > > > > > > > > HI, > > > > > > > > > I have created xml file for UI. > > > > > > > > I later added identifiers (@+/id) to few elements but the > > R.java > > > > file > > > > > > > > is not getting updated. > > > > > > > > There are many possible causes for this. Can you post the layout > > XML > > > > > > file? > > > > > > main.xml > > > > > 1KViewDownload --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Android Beginners" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/android-beginners?hl=en -~----------~----~----~----~------~----~------~--~---

