[#BloombergLP-bdlde-CharConvertUtf16-utf16ToUtf8-020] = xref:BloombergLP.adoc[BloombergLP]::xref:BloombergLP/bdlde.adoc[bdlde]::xref:BloombergLP/bdlde/CharConvertUtf16.adoc[CharConvertUtf16]::utf16ToUtf8 :relfileprefix: ../../../ :mrdocs: Load into the destination the UTF‐8 conversion of the UTF‐16 source. Return 0 on success and a non‐zero status otherwise. See the first `utf16ToUtf8` overload in this group for full contract details. == Synopsis Declared in `<bdlde_charconvertutf16.h>` [source,cpp,subs="verbatim,replacements,macros,-callouts"] ---- static int utf16ToUtf8( xref:bsl/string.adoc[bsl::string]* dstString, unsigned short const* srcString, std::size_t srcLengthInWords, std::size_t* numCodePointsWritten = 0, char errorByte = '?', xref:BloombergLP/bdlde/ByteOrder/Enum.adoc[ByteOrder::Enum] byteOrder = ByteOrder::e_HOST); ---- [.small]#Created with https://www.mrdocs.com[MrDocs]#