C++ (Qt)QByteArray arrBlock; QDataStream out(&arrBlock, QIODevice::WriteOnly); out << quint16(0) << "s";