I just want to ask a question because I am customizing the Kobo app on my android device.
I just want to ask how I can get the metada_username value to be displayed in my MainMenuActivity.xml after I scan the QR code.
PS: the QR code is already customized and has a metada_username included. Also in my project settings, it is displaying the metadata_username from the QR in the Form Metadata.
Please somebody help me!! Thank you in advance!
For example, if you want to get the metadata_username value from a QR code that contains a URL like this:
You can use the ZXing library to scan the QR code and get the raw data as a string:
Then you can use a URL parser library or method to parse the URL and get the query parameters as a map:
Finally, you can access the metadata_username value from the map by using its key:
To display the metadata_username value in your
MainMenuActivity.xml
, you can use aTextView
element and set its text attribute to the metadata_username value: