hi all, please help me how to send structs to a PC with sockets(NOKIA 6600)?
i have 2 structs,codes below:
typedef struct t_Connection_Command_Packet
{
TBuf<10> szCommand;
TInt i_CommandId;
TInt i_PacketLength;
TBuf<20> szIp;
TBuf<20> PhoneNo;
}COMMANDHEAD;

typedef struct t_Data_Packet
{
COMMANDHEAD commandheads;
TBuf<4096> PacketSound;
}DataPacket;

my sending codes like this:
datapackets.commandheads.PhoneNo.Copy(_L("13913904557"));
datapackets.commandheads.szCommand.Copy(_L("HB"));
datapackets.commandheads.szIp.Copy(_L("192.168.0.1"));
datapackets.PacketSound.Copy(_L("ddddddddddfdas"));
bufs.Copy((const TDesC8&)datapackets);
iSocket.Send((const TDesC8&)datapackets,0,iStatus);

right??Can the Pc receive the struct??
sorry,my English is very poor.