Josh1
June 30, 2016, 3:24pm
1
I am getting code errors in Android studio for all lines with R.layout.activity_main
The error is on the R. Can someone please help? Below is a few lines of the code. Thanks. -Josh
private BeaconManager beaconManager;
private Region region;
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.activity_main);
Are you sure you chose “Blank Activity” when creating a new project, and not “Empty”?
Josh1
July 1, 2016, 5:04pm
3
I don’t have the option for “Blank Activity”. Is there another option that will work?
Josh1
July 1, 2016, 5:19pm
4
After I changed the Android Manifest the error on the “R.” lines changed to errors on the following 2 lines:
getMenuInflater().inflate(R.menu.menu_main, menu); (The error is on the first “menu”)
if (id == R.id.action_settings) { (The error is on “action_settings”)
Both errors say “cannot resolve symbol”.