PC SOFT

FORUMS PROFESSIONNELS
WINDEVWEBDEV et WINDEV Mobile

Accueil → WINDEV Mobile 2024 → Decode a base64 string on Android
Decode a base64 string on Android
Débuté par Jozef DUIN, 06 juil. 2015 10:56 - 5 réponses
Membre enregistré
5 messages
Posté le 06 juillet 2015 - 10:56
Perhaps a very simple question but I just can't find a solution to decode a base64 string in windev on Android? (When using Uncrypt on Android, encodeBASE64 is ignored)
Posté le 06 juillet 2015 - 14:47
Hi Jozef

From the top of my head, the encodebase64 is not available for android,
so you need to either decode it yourself in wlanguage (the algorithm for
base64 is not very complex) or find a java function doing that and call it.

Best regards

--
Fabrice Harari
International WinDev, WebDev and WinDev mobile Consulting

Already there: WXShowroom.com, WXReplication (open source)
Coming soon: WXEDM (open source)
More information on http://www.fabriceharari.com



On 7/6/2015 2:56 AM, Jozef DUIN wrote:
Perhaps a very simple question but I just can't find a solution to
decode a base64 string in windev on Android? (When using Uncrypt on
Android, encodeBASE64 is ignored)
Membre enregistré
37 messages
Popularité : +1 (1 vote)
Posté le 07 juillet 2015 - 16:42
Hi,
Decrypting a stream in base64binary format
To decrypt a string encrypted in base64, you must use:
ResultString = Uncrypt(EncryptedString, "", cryptNone)


see help http://doc.windev.com/en-US/…

and be carefull with ANSI and UNICODE string convertion

Best regards
Membre enregistré
3 655 messages
Popularité : +175 (223 votes)
Posté le 24 septembre 2018 - 19:21
Hi, I haver the version 21 of Windev movile, thren I have a problem, basicaly I can't use the funtion encodeBASE64, there some alternatives to convert a image and send it in a request?
Posté le 24 septembre 2018 - 22:37
Hi Alexandro,

considering the speed of evolution of Android, I strongly suggest that
you upgrade to 23, and solve your base64 problem that way...

However, if you still want to code in v21, then you can create your own
function to encode in base64, it's not very complex and there are
algorithm available easily on the web

You can also simply use buffertohexa, and transfer your binary image as
an hexa encoded string (much longer than base64, though)

best regards

--
Fabrice Harari
International WinDev, WebDev and WinDev mobile Consulting

Free Video Courses, free WXShowroom.com, open source WXReplication, open
source WXEDM.

More information on http://www.fabriceharari.com


On 9/24/2018 11:21 AM, Alejandro wrote:
Hi, I haver the version 21 of Windev movile, thren I have a problem,
basicaly I can't use the funtion encodeBASE64, there some alternatives
to convert a image and send it in a request?