Android Question Error Parse Library

omidaghakhani1368

Well-Known Member
Licensed User
Longtime User
Hi.
I use parse library last month and it worked good.
But now i use push in my app but when start app,unfurtanately stoped app
i attach project
 

Attachments

  • a.zip
    12.2 KB · Views: 152

Ohanian

Active Member
Licensed User
Longtime User
Hi,
It seems that you missed this part:

Version 1.1 of this library specified the Parse keys in a Parse.Initialize method. This method no longer exists in version 1.2 and later. This is because it it was called from within an Activity, but if Android killed your process and then tried to restart the Parse Service this failed because the service started without the activity being created and so was not initialised correctly. Initialisation now occurs on Application creation and requires the library Application class name to be registered in the manifest and the Parse keys to be specified as an xml resource. When the application is loaded you will see the values in the xml file echoed to the filtered logs.

You also need to place a file called res.xml in your project Objects/res/xml folder and make it read-only. The xml folder does not exist in the project archive but will be created at your first compile. The contents of res.xml should specify your Parse keys as follows :

B4X:
<!--?xml version="1.0" encoding="utf-8"?-->
<data>
<data1 value="YourParseApplicationAppID" />
<data2 value="YourParseApplicationClientKey" />
</data>
 
Upvote 0

Ohanian

Active Member
Licensed User
Longtime User
Hi,
there's no xml/res.xml in your project.
post your project with all files.
 
Upvote 0

Ohanian

Active Member
Licensed User
Longtime User
Hi,

Test the attached project, working fine here (I’m using Parse lib 1.40)
 

Attachments

  • Push.zip
    12.8 KB · Views: 197
Upvote 0
Top