rendering sandbox error when use ConstraintLayout preview in AndroidStudio

created at 08-23-2021 views: 15

This problem is reported mainly in my Module project. It is normal for the main project to use ConstraintLayout. I don't know what bugs. Just follow the prompts to modify

Error message

Rendering sandbox error
Property access not allowed during rendering   
    at java.lang.System.getProperties(System.java:718)   
    at com.intellij.idea.IdeaLogger.logErrorHeader   ... (IdeaLogger.java:110)

solution

Find the studio and press the idea.properties file under the directory /bin, and add the following content:

android.render.sandbox=false

Then restart AndroidStudio to render the layout file normally for preview

created at:08-23-2021
edited at: 08-23-2021: