When Android Studio removes the module, it needs to be removed by clicking "-" in project structure, when the small phone icon disappears, but this time the module is not deleted from the hard drive, it is just out of the relationship with project. If this is the time to find that the module is not deleted, what should I do to build a relationship with Project again? This experience hopes to help you! PS: Actually removing the module is good, so you don't have to load so many module at Gradle, you can speed it up, similar to closing a project in Eclipse.
Method/Step
-
, only the three module actionbartest, Billcalculator, and MyApplication are associated with project because the three module has a small phone icon, Now we re-establish the app module with project.
-
Double-click Project's Settings.gradle, and you'll see the three module that has a relationship with project just now.
-
Enter include ': Module_name ', where Module_name is the name of the module you want to connect to, and then synchronize (sync). Note that the ":" cannot be omitted, and you can click on "Sync Now" in the upper-right corner, or you can synchronize by File->synchronize.
Android Studio Add module that has already been removed