简体   繁体   中英

@Override Error in Android Studio

I'm new in Android Studio and Java. After I create any android projects, they have an error at first! 在此处输入图片说明

Error is for "@Override" When I hold mouse on it, it says "method does not override method from superclass"

What I should do to solve this error?

Thanks.

When you add @Override to a method, if

method does not override method from superclass

appears. It means IDE can't find the method with same signature in its super class.

From my view, I guess you didn't add the library which contains AppCompatActivity properly. Please have it examined.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM