Android Studio shows wrong file contents

后端 未结 9 1429
失恋的感觉
失恋的感觉 2020-11-21 11:09

I have an odd problem with Android Studio. Here is how my class file looks like on Android Studio

And here is what it looks like on a text editor.

<

相关标签:
9条回答
  • 2020-11-21 11:53

    I changed my projects location and it solved my problem. This happened when my system was accidently shut down due to power failure.

    0 讨论(0)
  • 2020-11-21 11:54

    UPDATE: Quicker solution by the user Hong given below:

    Delete the caches folder: C:\Users\my_user_name\.AndroidStudio3.3\system\caches

    =====================

    Here's what worked for me.

    1. Close Android Studio
    2. Go to C:\Users*your username*
    3. Locate the Android Studio settings directory named .AndroidStudioX.X (X.X being the version)
    4. Rename it to something like old.AndroidStudioX.X
    5. Start Android Studio, and when it asks if you want to import settings, choose the old directory

    This should fix the issue.

    0 讨论(0)
  • Close Android studio and then delete the caches folder: C:\Users\user_name\.AndroidStudio3.4\system\caches

    0 讨论(0)
提交回复
热议问题