Preference Activity not found error

demasi

Active Member
Licensed User
Longtime User
Hello,

I'm trying to use the preference activity, tested the example supplied and all worked well.
to use in my own project, I need to put the preference activity code in other activity, but when I do this I get the following error:

android.content.ActivityNotFoundException: Unable to find explicit activity class {anywheresoftware.b4a.samples.preferenceactivity/anywheresoftware.b4a.samples.preferenceactivity.preferences}; have you declared this activity in your AndroidManifest.xml?

I tried with the example, just moving the code to another activity and starting that activity. It gives this error always.
I tried checking the option to not overwrite the manifest, but the result is the same.
So, I think there's no error with the manifest file, but even I tried to add the preference activity to the manifest file, and this also not worked.

can someone please help me?
thank you
 

demasi

Active Member
Licensed User
Longtime User
Preference Activity in anorter activity

Thank you Erel.

I´ve tried this, using this line in the manifest, but it not worked.
I´ve tried your example, and it worked ok. But when I move the code to another activity, I have this message cannot find the activity.
Any problem in moving the code to another activity, or I must use this code only in the main activity?
:BangHead:
 
Upvote 0

demasi

Active Member
Licensed User
Longtime User
Found the error

Hello Erel,

I´ve found the error, it was the name of my new activity, it was begining with upper case, but I was calling all lower case. :signOops:

Thank your for your attention.
 
Upvote 0
Top