Author | Topic: ToBase64 | |
---|---|---|
Salvatore Megna | ToBase64 on Fri, 29 Jun 2018 16:35:20 +0200 Good morning Can I with ToBase64 convert to a single string and not formatted to 72 characters? | |
Andreas Gehrs-Pahl | Re: ToBase64 on Fri, 29 Jun 2018 11:56:29 -0400 Salvatore, >Can I with ToBase64 convert to a single string and not formatted to 72 >characters? You can remove the line breaks: StrTran(ToBase64(cBinary), chr(13) + chr(10)) But that might break the Base64 encoding, which might require a maximum length of 64 or 76 characters per line, depending on the RFC (or purpose) of the encoding. You might also have to replace any "+" and "/" characters, if that is required. For more details see: https://en.wikipedia.org/wiki/Base64 Also, the ASINet function ToBase64() has been replaced with the (identical) Bin2Base64() function in Xbase++ 2.0 (which is part of the Foundation product and located in the XppRT1.dll). Hope that helps, Andreas Andreas Gehrs-Pahl Absolute Software, LLC phone: (989) 723-9927 email: Andreas@AbsoluteSoftwareLLC.com web: http://www.AbsoluteSoftwareLLC.com [F]: https://www.facebook.com/AbsoluteSoftwareLLC |