Click here to Skip to main content
15,918,808 members
Home / Discussions / C#
   

C#

 
GeneralRe: Socket programming Pin
Luc Pattyn2-Dec-10 2:20
sitebuilderLuc Pattyn2-Dec-10 2:20 
AnswerRe: Socket programming Pin
Tichaona J2-Dec-10 4:08
Tichaona J2-Dec-10 4:08 
QuestionConversion of a object into a particular datetime format Pin
Varun Sareen1-Dec-10 17:43
Varun Sareen1-Dec-10 17:43 
AnswerRe: Conversion of a object into a particular datetime format Pin
OriginalGriff1-Dec-10 21:38
mveOriginalGriff1-Dec-10 21:38 
QuestionCan not deserialize [modified] Pin
Jacob D Dixon1-Dec-10 11:39
Jacob D Dixon1-Dec-10 11:39 
AnswerRe: Can not deserialize Pin
jschell1-Dec-10 12:16
jschell1-Dec-10 12:16 
AnswerRe: Can not deserialize Pin
Luc Pattyn1-Dec-10 12:17
sitebuilderLuc Pattyn1-Dec-10 12:17 
GeneralRe: Can not deserialize Pin
Jacob D Dixon1-Dec-10 12:30
Jacob D Dixon1-Dec-10 12:30 
Luc I think you are right about the StateObject.BufferSize. It really was the only way I could think to do it.

So I'm receiving the data asynchronously. So as you can tell it is doing a loop passing the StateObject until all data is received. I am reading only 1024 bytes.

So lets say I send the server 1048 bytes. The server will read 1024 bytes then call BeginReceive again. Now the server should only receive 24 bytes this next go around due to 1024 + 24 = 1048. So this time it is seeing that it received LESS than 1024 which tells me that we are done receiving all the data.

So lets say we send 2048 (1024 + 1024).. then this code will not work because after the first time it will call begin receive and get 1024 bytes, then it will call it again and receive 1024 bytes, then it will call it a third time and not get any bytes (which won't execute the code and the data is lost.

Hope I explained / understand that correctly. I'm thinking this could be my issue?
AnswerRe: Can not deserialize Pin
Luc Pattyn1-Dec-10 13:06
sitebuilderLuc Pattyn1-Dec-10 13:06 
GeneralRe: Can not deserialize Pin
Jacob D Dixon1-Dec-10 14:48
Jacob D Dixon1-Dec-10 14:48 
AnswerRe: Can not deserialize Pin
Luc Pattyn1-Dec-10 15:02
sitebuilderLuc Pattyn1-Dec-10 15:02 
GeneralRe: Can not deserialize Pin
Jacob D Dixon1-Dec-10 16:21
Jacob D Dixon1-Dec-10 16:21 
GeneralRe: Can not deserialize Pin
Luc Pattyn1-Dec-10 16:46
sitebuilderLuc Pattyn1-Dec-10 16:46 
GeneralRe: Can not deserialize [modified] Pin
Jacob D Dixon1-Dec-10 17:11
Jacob D Dixon1-Dec-10 17:11 
GeneralRe: Can not deserialize Pin
Luc Pattyn1-Dec-10 22:22
sitebuilderLuc Pattyn1-Dec-10 22:22 
GeneralRe: Can not deserialize Pin
Jacob D Dixon2-Dec-10 4:57
Jacob D Dixon2-Dec-10 4:57 
AnswerRe: Can not deserialize Pin
Luc Pattyn2-Dec-10 5:19
sitebuilderLuc Pattyn2-Dec-10 5:19 
GeneralRe: Can not deserialize Pin
Jacob D Dixon2-Dec-10 6:09
Jacob D Dixon2-Dec-10 6:09 
GeneralRe: Can not deserialize Pin
Luc Pattyn2-Dec-10 6:30
sitebuilderLuc Pattyn2-Dec-10 6:30 
GeneralRe: Can not deserialize Pin
Jacob D Dixon2-Dec-10 7:56
Jacob D Dixon2-Dec-10 7:56 
GeneralRe: Can not deserialize Pin
Luc Pattyn2-Dec-10 8:20
sitebuilderLuc Pattyn2-Dec-10 8:20 
QuestionTrying to deal with the memory leak in the Flash Player Pin
jbradshaw1-Dec-10 6:09
jbradshaw1-Dec-10 6:09 
AnswerRe: Trying to deal with the memory leak in the Flash Player Pin
Luc Pattyn1-Dec-10 6:52
sitebuilderLuc Pattyn1-Dec-10 6:52 
GeneralRe: Trying to deal with the memory leak in the Flash Player Pin
jbradshaw1-Dec-10 7:27
jbradshaw1-Dec-10 7:27 
QuestionRe: Trying to deal with the memory leak in the Flash Player Pin
jbradshaw1-Dec-10 7:32
jbradshaw1-Dec-10 7:32 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.