StringConversionConvertToFixedLength Method (String, Int32, StringConversionGetBytes) |
Convert a fixed length string to an array of bytes.
Only works with 1 byte character encoded strings (eg ASCII).
Namespace:
Demo3D.PLC
Assembly:
PLC (in PLC.dll) Version: 15.0.2.11458
Syntaxpublic static byte[] ConvertToFixedLength(
string str,
int charCount,
StringConversionGetBytes encoding
)
Parameters
- str
- Type: SystemString
String to encode. - charCount
- Type: SystemInt32
Max characters in string to convert. - encoding
- Type: Demo3D.PLCStringConversionGetBytes
String converter.
Return Value
Type:
ByteEncoded array of bytes.
See Also