@zahaiak I don't think so. The JavaScript function looks good (change //Example to /star Example star/). It's more a problem of passing the variables right way coming from inside AppInventor.
in this example the label above shows the result: in this case "RESULT". Here you have only to adapt it to your app. I have written your function to a textBox that you can also use to test some JS code.
For example, change the return value to taxNumber (can be done in the textBox at runtime) - then you see the result in the label. You'll get taxNumber instead of "RESULT", one proof more that it works.
I'm so glad that you help me with this problem. You are done it so perfectly. However, Tags and Value Length should be hex number before covering them to Base 64. Please see the Hex Representation attached.
I'm sorry, I confused you. The way the project work is
First is (from Text to bytes)
Second is (from bytes to Hex)
Then (from Hex To base64)
this way will work perfectly.