Need to change R.java


#1

I know you should never touch this file but…

My field crime_list_item_titleTextView used in CrimeListFragment.java is listed as crime_list-item_titleTextView. In short there is a hyphen where there should be an underscore. I have tried F5 and I have also tried to refresh the project. No luck. Clean does not work either and if I uncheck Automatic Build and try to Build the project manually I get the Null pointer error.

Any help would be greatly appreciated.

thanks, Joanne


#2

[quote=“jgolding”]I know you should never touch this file but…

My field crime_list_item_titleTextView used in CrimeListFragment.java is listed as crime_list-item_titleTextView. In short there is a hyphen where there should be an underscore. I have tried F5 and I have also tried to refresh the project. No luck. Clean does not work either and if I uncheck Automatic Build and try to Build the project manually I get the Null pointer error.

Any help would be greatly appreciated.

thanks, Joanne[/quote]

Go to the list_item_crime.xml file and change the id of the text view to “crime_list_item_titleTextView” and save the changes, that should solve the problem.


#3

[quote=“rudra123”][quote=“jgolding”]I know you should never touch this file but…

My field crime_list_item_titleTextView used in CrimeListFragment.java is listed as crime_list-item_titleTextView. In short there is a hyphen where there should be an underscore. I have tried F5 and I have also tried to refresh the project. No luck. Clean does not work either and if I uncheck Automatic Build and try to Build the project manually I get the Null pointer error.

Any help would be greatly appreciated.

thanks, Joanne[/quote]

Go to the list_item_crime.xml file and change the id of the text view to “crime_list_item_titleTextView” and save the changes, that should solve the problem.[/quote]

Many, many thanks.
That cleaned it up.

Joanne