ONLINE HELP
 WINDEVWEBDEV AND WINDEV MOBILE

WINDEV
WindowsLinuxUniversal Windows 10 AppJavaReports and QueriesUser code (UMC)
WEBDEV
WindowsLinuxPHPWEBDEV - Browser code
WINDEV Mobile
AndroidAndroid Widget iPhone/iPadIOS WidgetApple WatchMac CatalystUniversal Windows 10 App
Others
Stored procedures
Encodes a character string or a buffer. To decode the result, simply use Decode.
Example
// Encode an image in Base64
Res is string = Encode(fLoadBuffer("MyImage.jpg"), encodeBASE64)
// Encode a URL
Info(Encode("https://www.google.fr/?", encodeURLFromAnsi) + ...
Encode(Encode("https://www.google.fr/?é", encodeURLFromAnsi), encodeURLParameter))
Syntax
<Result> = Encode(<Data> [, <Encoding format>])
<Result>: Character string
Data encoded according to the selected format.
<Data>: Character string or Buffer
Data to encode.
<Encoding format>: Optional Integer constant
Format for encoding data:
encodeBASE64
(Default value)
BASE 64 format (complies with the RFC 4648 standard). Encoded text contains only printable characters and CRs (Carriage Returns).
PHP Carriage returns (CR) are removed.
encodeBASE64NoCRBASE 64 format (complies with RFC 4648 standard) without RCs (Carriage Returns). The encoded text contains printable characters only.
PHP This constant is not available.
encodeBASE64URLBASE 64 URL format (complies with the RFC 4648 standard). The encoded text contains printable characters only.
PHP This constant is not available.
encodeBASE85BASE 85 format. The encoded text contains printable characters only.
AndroidAndroid Widget Unsupported format.
PHP This constant is not available.
encodePCSASCII format. The encoded text contains printable characters only.
AndroidAndroid Widget Unsupported format.
encodeURLFromAnsiURL format. The encoded text only contains characters allowed in a URL. The text to encode is an ANSI string.
PHP This constant is not available.
encodeURLFromUnicodeURL format. The encoded text only contains characters allowed in a URL. The text to encode is a Unicode string.
PHP This constant is not available.
encodeURLFromUTF8URL format. The encoded text only contains characters allowed in a URL. The text to encode is a UTF-8 string.
PHP This constant is not available.
encodeURLParameterThis constant is used when it is necessary to pass a given URL (URL A) as a parameter to another URL (URL B). The reserved characters of URL A (//,?...) are encoded.
URL A (to be encoded) must be a valid URL. If it has its own parameters, they must have been encoded with one of the following constants: encodeURLFromAnsi, encodeURLFromUnicode or encodeURLFromUTF8.
PHP This constant is not available.
encodeUUEncodeUUEncode format. The encoded text contains printable characters only.
AndroidAndroid Widget Unsupported format.
Business / UI classification: Business Logic
Component: wd280std.dll
Minimum version required
  • Version 22
This page is also available for…
Comments
IMAGEN /STRING
//VOU MOSTRAR HOJE, COMO TRANSFORMAR
//UMA IMAGEN EM STRING E TRANSFORMAR
//UMA STRING EM UMA IMAGEM

IMG_IMAGEN_1 = "c:\ICONES\IC_OK_N.PNG" // VALIDADO
EDT_IMAGEN_TEXTO=Encode(fChargeBuffer(IMG_IMAGEN_1),encodeBASE64)
//--
IMG_IMAGEM_VOLTA = Decode(EDT_IMAGEN_TEXTO,encodeBASE64)

//BLOG COM VIDE E EXEMPLO

http://windevdesenvolvimento.blogspot.com/2017/08/aula-1237-windev-imagen-006-encodedecode.html

https://www.youtube.com/watch?v=KLr4-1wg_WQ


De matos
11 Aug. 2017