AndroidStudio : Cannot resolve symbol MainActivity

后端 未结 7 1833
说谎
说谎 2021-01-17 13:07

I got an error \"Cannot resolve symbol MainActivity\" on this code.



        
7条回答
  •  甜味超标
    2021-01-17 13:38

    project structure, right click on src folder->Mark directory as-> sources root.

    Now your mainactivity.java file with 'j' symbol to change to 'c' symbol.

    The error was that the project did not have a valid source folder from where it could look for the activity class.

提交回复
热议问题