pdoria
31st July 2009, 13:46
Hi,
I have this structure:
typedef struct
{
uint32 status_change_id;
boolean result_code;
uint8 reserved[3]; /* Set to 0 */
} driver_id_receipt_data_type;
I'm trying to:
driver_id_receipt_data_type receipt;
QVariant packet;
// after filling the structure's members with data...
packet.setValue(receipt); // ERROR Line
Could somebody please tell me what's wrong with this code?
I have this function:
void send_FleetManagementPacket(QDataStream & dstream, QVariant packet);
which serves to send to arbitrary data to a stream.
I was hoping to pass the data through a QVariant thus eliminating the need for a ton of orverloaded functions...
TIA,
Pedro
I have this structure:
typedef struct
{
uint32 status_change_id;
boolean result_code;
uint8 reserved[3]; /* Set to 0 */
} driver_id_receipt_data_type;
I'm trying to:
driver_id_receipt_data_type receipt;
QVariant packet;
// after filling the structure's members with data...
packet.setValue(receipt); // ERROR Line
Could somebody please tell me what's wrong with this code?
I have this function:
void send_FleetManagementPacket(QDataStream & dstream, QVariant packet);
which serves to send to arbitrary data to a stream.
I was hoping to pass the data through a QVariant thus eliminating the need for a ton of orverloaded functions...
TIA,
Pedro