Pravinsingh Waghela Pravinsingh Waghela - 6 months ago 593
Android Question

Project already contains module with this name -- Android Studio

I had successfully imported a

Module
in my Application project in
Android Studio
.
Then I deleted or removed the module by following the below link:

How to delete a module in Android Studio

I also removed the project module from the
dependencies
of my
build.gradle(app)
file.

Now, When I need to again include the same module project in my Andorid Application, it doesn't allows me, and gives the
Project already contains module with the same name
error.

I had check in my
Project, Package, Android
Structure but the project module which i need to Import and add as a Module Project is not there but still it say it already exist.

Can anyone help me to overcome this issue.??

Answer

If somebody faces this issue, except removing the Folder containing the old module also remove from the settings.gradle file the line corresponding to the old module: include ':youroldmodule'. If you dont remove that line manually, 2 modules with the same name will appear when trying to add module dependency.