Xceed Binary Encoding Library Documentation
Xceed Binary Encoding control reference / Methods / FromString method
In This Topic
    FromString method
    In This Topic

    Description

    Converts a string containing only ASCII characters to a variant byte array.

    The FromString method allows you to convert a string (which was originally converted to a string using the ToString method) back to a variant byte array. This is especially useful when the encoded or decoded data was transferred or stored as a string because it must be converted back to a variant byte array before it can be used by the appropriate method or property.

    Parameters 

    Parameter Description
    sData The string to convert.

    Return value

    Returns a variant byte array containing the converted ASCII characters.

    Associated properties

    None

    Declaration (DXceedBinaryEncoding) Copy Code
    HRESULT FromString( [in] BSTR sData, [out,retval] VARIANT* vaResult );
    Declaration (IXceedBinaryEncoding) Copy Code
    HRESULT FromString
    (
      [in] BSTR sData,
      [out, size_is(,*pdwDataSize)] BYTE** ppcData,
      [out] DWORD* pdwDataSize
    );

    Related topics

    To convert a variant byte array to a string, the ToString method can be used.