Lasso Soft Inc. > Home

[ Bytes->ImportString ]

Method

[Bytes->ImportString] imports a string into the byte stream converting each character using the desired character encoding. The method requires two parameters, the data to be imported and the character set which should be used to encode that data.

  • Syntax
local(ByteStream = Bytes(1024, 256))
#ByteStream->ImportString('String', 'Encoding')
Examples
  • Beginner

To import a string into a bytes stream:

Use the [Bytes->ImportString] method. The following example imports a string using ISO-8859-1 encoding.

Code

local(Bytes = Bytes('This is a string'))
#Bytes->ImportString('This is some more string', 'ISO-8859-1')

Recent Comments

No Comments found

Please note that periodically LassoSoft will go through the notes and may incorporate information from them into the documentation. Any submission here gives LassoSoft a non-exclusive license and will be made available in various formats to the Lasso community.

LassoSoft Inc. > Home

 

 

©LassoSoft Inc 2015 | Web Development by Treefrog Inc | PrivacyLegal terms and Shipping | Contact LassoSoft