Contextioner Contextioner - 12 days ago 5
Android Question

Cannot add java files to the paid Product Flavor

I have created a project with two flavours. The free flavour I can add java files but the paid on I cannot create java and res directory to add java files. I have manually created both the free and paid directory.

productFlavors {
free {
applicationId "com.sagar.joker.free"
}
paid {
applicationId "com.sagar.joker.paid"
}
}


Check the Project Structure

Answer

You can choose active flavor in Android Studio in BuildVariants in left bottom corner.

choose flavor