Click here to Skip to main content
15,897,518 members
Home / Discussions / C#
   

C#

 
AnswerRe: Component Versioning and the CLR Pin
Not Active1-Dec-11 17:18
mentorNot Active1-Dec-11 17:18 
GeneralRe: Component Versioning and the CLR Pin
Richard Andrew x641-Dec-11 17:21
professionalRichard Andrew x641-Dec-11 17:21 
GeneralRe: Component Versioning and the CLR Pin
Rob Philpott2-Dec-11 2:46
Rob Philpott2-Dec-11 2:46 
QuestionC# Sockets Pin
Sautin.net1-Dec-11 7:48
Sautin.net1-Dec-11 7:48 
AnswerRe: C# Sockets Pin
Addy Tas1-Dec-11 12:45
Addy Tas1-Dec-11 12:45 
AnswerRe: C# Sockets Pin
jschell1-Dec-11 13:39
jschell1-Dec-11 13:39 
AnswerRe: C# Sockets Pin
Jitendra Parida - Jeetu1-Dec-11 21:41
Jitendra Parida - Jeetu1-Dec-11 21:41 
AnswerRe: C# Sockets Pin
BobJanova1-Dec-11 23:52
BobJanova1-Dec-11 23:52 
You are making a common mistake in assuming that the 4 bytes you want for your header information will always be received together. This will be the case 99% of the time, but it's not guaranteed, and on a busy stream you may well get partial messages, which will send your whole receive logic out of line (i.e. if the calls to socket.Receive only get 3 bytes).

Receive will block until the data is available. Are you sure your server is actually sending (8+arrayLength) bytes?

I recommend you build your solution on top of an existing message-based TCP protocol like the one in my article[^], if you need the two way connectivity and don't feel like configuring WCF to do what you want. I think I saw another article that does something similar but allows you to send complex types, but I don't have a link to that handy.
AnswerRe: C# Sockets (Solved) Pin
Sautin.net2-Dec-11 9:33
Sautin.net2-Dec-11 9:33 
QuestionPrinting in C# on Thermal Printer Pin
vijay.victory1-Dec-11 6:26
vijay.victory1-Dec-11 6:26 
AnswerRe: Printing in C# on Thermal Printer Pin
Dan Mos1-Dec-11 6:43
Dan Mos1-Dec-11 6:43 
GeneralRe: Printing in C# on Thermal Printer Pin
vijay.victory1-Dec-11 7:07
vijay.victory1-Dec-11 7:07 
AnswerRe: Printing in C# on Thermal Printer Pin
Dan Mos1-Dec-11 7:19
Dan Mos1-Dec-11 7:19 
GeneralRe: Printing in C# on Thermal Printer Pin
vijay.victory1-Dec-11 7:58
vijay.victory1-Dec-11 7:58 
Questiondom xml in c# like in php simpledomparser Pin
Jayapal Chandran1-Dec-11 3:50
Jayapal Chandran1-Dec-11 3:50 
AnswerRe: dom xml in c# like in php simpledomparser Pin
Richard MacCutchan1-Dec-11 5:19
mveRichard MacCutchan1-Dec-11 5:19 
QuestionC# remoting server and client problem with connection Pin
kornkimhour1-Dec-11 3:42
kornkimhour1-Dec-11 3:42 
AnswerRe: C# remoting server and client problem with connection Pin
#realJSOP1-Dec-11 5:08
professional#realJSOP1-Dec-11 5:08 
GeneralRe: C# remoting server and client problem with connection Pin
BobJanova1-Dec-11 5:15
BobJanova1-Dec-11 5:15 
GeneralRe: C# remoting server and client problem with connection Pin
fjdiewornncalwe1-Dec-11 5:16
professionalfjdiewornncalwe1-Dec-11 5:16 
AnswerRe: C# remoting server and client problem with connection Pin
Richard MacCutchan1-Dec-11 5:18
mveRichard MacCutchan1-Dec-11 5:18 
GeneralRe: C# remoting server and client problem with connection Pin
Dan Mos1-Dec-11 5:36
Dan Mos1-Dec-11 5:36 
Questionjson in c#.net framework 2.0 Pin
Jayapal Chandran1-Dec-11 3:39
Jayapal Chandran1-Dec-11 3:39 
AnswerRe: json in c#.net framework 2.0 Pin
BobJanova1-Dec-11 3:52
BobJanova1-Dec-11 3:52 
GeneralRe: json in c#.net framework 2.0 Pin
Jayapal Chandran2-Dec-11 0:58
Jayapal Chandran2-Dec-11 0:58 

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.