Reputation: 33996
When I tried to upload my app to the android play store I got an error message which is "You need to use a different package name because "com.example" is restricted"
. So I went to eclipse and looked for packages named com.example
.
These are the contents of the only two folders with packages:
/ src
myapp.mainclass
/ gen
com.example.myapp *
myapp.mainclass
*com.example.myapp
seems to be the reason I'm getting the error message, it's identical to myapp.mainclass
. However I cannot delete it or re factor it, every time I remove it it's auto-generated again so there is no way I can upload the app to the Play Store, since com.example is impossible to remove.
Anyone encountered this issue or has any ideas on how to upload the app?
Upvotes: 3
Views: 12874
Reputation: 169
you should change your applicationID(usually called "package address") you can change com.example to your own address by following steps.
then, you can not see "com.example..." anymore.
Upvotes: 0
Reputation: 386
A more comprehensive way to rename the package is to:
Right click the project name -> Android Tools -> Rename Application Package -> and then type in your new package name.
It seems to update the entire project in the one go here.
Upvotes: 2
Reputation: 12444
After renaming your package in src folder, rename it also in the AndroidManifest.xml
with the same name.
Upvotes: 11
Reputation: 611
Edit Package name and then in the AndroidManifest.xml with the same package name, clean your project, rebuild, now i hope this will work.
Upvotes: 1
Reputation: 4638
delete the gen folder. and clean the project. your gen folder will get create automatically. At the same time you should change the package name in Manifest file. it should be which you want.
Upvotes: 0
Reputation: 425
You can create a new project in eclipse using your new package name and after that copy past your java file and any res files into new project.
Upvotes: 0