   distiguish an object ,, that is send by socket
  hi,i have created an array UCHAR * m_array;m_array = new UNCHAR [size]i saved data in it ,, that PCM data (pulse code modulation)now i want to send this (array) throught socket.but i want to place some TAG before this that helps me on server side that i m recivng an arrayCString str = " <>"; E.G  ..  ?  = str + m_array( i.e object of array )    in which(?) i store it.  m_array is not a string data;how can i addup this type of tag that helps me on server side to distiguish this that it is an array object ,, not ohter data...   if its successfull to add up a tagthen using CSocket->send ( ...... , .. , ...);it can be sendPlz reply me  about adding a tagthanx  
char buf[256]; //just some numberstrcpy(buf, "<TAG>");strcat(buf, m_array);// now send buffer on its happy way   that is assumming m_array is NULL terminated"A soldier is a part of the 1% of the population that keeps the other 99% free"  - Lt. Colonel Todd, 1/38th Infantry, Ft. Benning, GA   [edited by - ncsu121978 on February 6, 2004 10:22:04 AM] [edited by - ncsu121978 on February 6, 2004 10:22:41 AM];but  m_array is a sound data ... how it is a NULL terminated..its not a string    strcat  etc  r string functions    will thay help to concatinate  + m_array (sound data.)  thanx;char buf[big_size];strcpy(buf, "<TAG>");memcpy(m_array, (buf+strlen(buf)), size);// send buffer on its happy way "A soldier is a part of the 1% of the population that keeps the other 99% free"  - Lt. Colonel Todd, 1/38th Infantry, Ft. Benning, GA ;  ok...but now how can i seperate them i means ..my tag and m_array .. when i will revieve them on other side ( on specific Client Socket).  assume i get them on other side and want to seperate sound data (m_array) from my tag.    where i will play my m_array  thanx  ;  Since you are writing the code for server and clientyou should know how big your tag is.if you go really simple and tag your data with an int then on the server side you recieve to a buffer, andso your data is simply at(buffer+sizeof(int))but the same effect works for any sized tag