0

I do have a MessageRVAdapter in my project directory but I don't know why my app isn't finding this class. I get the following problem in MainActivity.java within app\src\main\java\com\example\chatbot:

cannot find symbol
    private MessageRVAdapter messageRVAdapter;
            ^
  symbol:   class MessageRVAdapter
  location: class MainActivity 

Here is my code:

// creating a variable for array list and adapter class.
private ArrayList<com.example.chatbot.MessageModal> messageModalArrayList;
private MessageRVAdapter messageRVAdapter;

Here is what my directory looks like

https://i.stack.imgur.com/JPAMe.jpg

  • 1
    First look if there is an `import`. Second is `MessageRVAdapter` in the right package ? Third let Android Studio find the import for you. – PeterMmm Mar 13 '22 at 09:48
  • I figured it out!! For some reason it had MessageRVAdapter down as private but it should have been public in the code within MainActivity.java. – Daniel_devil Mar 13 '22 at 15:13

0 Answers0