Click here to Skip to main content
15,914,010 members
Home / Discussions / C#
   

C#

 
GeneralRe: Reading large data with TcpClient Pin
Pete O'Hanlon21-Sep-10 4:44
mvePete O'Hanlon21-Sep-10 4:44 
QuestionRe: Reading large data with TcpClient Pin
Chesnokov Yuriy21-Sep-10 5:13
professionalChesnokov Yuriy21-Sep-10 5:13 
AnswerRe: Reading large data with TcpClient Pin
Pete O'Hanlon21-Sep-10 7:49
mvePete O'Hanlon21-Sep-10 7:49 
QuestionCorrect deserialization with BinaryFormatter Pin
Chesnokov Yuriy20-Sep-10 20:19
professionalChesnokov Yuriy20-Sep-10 20:19 
AnswerRe: Correct deserialization with BinaryFormatter Pin
Paw Jershauge21-Sep-10 0:35
Paw Jershauge21-Sep-10 0:35 
GeneralRe: Correct deserialization with BinaryFormatter Pin
Chesnokov Yuriy21-Sep-10 1:39
professionalChesnokov Yuriy21-Sep-10 1:39 
GeneralRe: Correct deserialization with BinaryFormatter Pin
Paw Jershauge21-Sep-10 2:18
Paw Jershauge21-Sep-10 2:18 
GeneralRe: Correct deserialization with BinaryFormatter Pin
Chesnokov Yuriy21-Sep-10 2:47
professionalChesnokov Yuriy21-Sep-10 2:47 
It is very simple, MemoryStream contains your data for deserialization.

With MemoryStream.GetBuffer(); you may get access to underlying byte[] array.

It needs to check that in that array first bytes are valid BinaryHeader structure used inernally by BinaryFormatter during deserialization call.

If there is garbage in the MemoryStream then BinaryFormatter will throw exception. I need to avoid that exception and make sure correct data will be passed for deserialization.

Finally I found that link that resolves the issue http://primates.ximian.com/~lluis/dist/binary_serialization_format.htm[^]
Чесноков

QuestionC# picture box Pin
C.CoderCreator20-Sep-10 20:05
C.CoderCreator20-Sep-10 20:05 
AnswerRe: C# picture box Pin
Pete O'Hanlon20-Sep-10 22:06
mvePete O'Hanlon20-Sep-10 22:06 
QuestionMicrosoft.Sharepoint.dll Reference. Pin
avi_dadi200220-Sep-10 20:00
avi_dadi200220-Sep-10 20:00 
AnswerRe: Microsoft.Sharepoint.dll Reference. Repost Pin
Richard MacCutchan20-Sep-10 21:19
mveRichard MacCutchan20-Sep-10 21:19 
Questionwhat gets passed to what class?? Pin
stephen.darling20-Sep-10 19:52
stephen.darling20-Sep-10 19:52 
AnswerMessage Closed Pin
20-Sep-10 21:09
stancrm20-Sep-10 21:09 
GeneralRe: what gets passed to what class?? Pin
stephen.darling20-Sep-10 21:29
stephen.darling20-Sep-10 21:29 
AnswerRe: what gets passed to what class?? Pin
OriginalGriff20-Sep-10 21:43
mveOriginalGriff20-Sep-10 21:43 
GeneralRe: what gets passed to what class?? Pin
stephen.darling20-Sep-10 21:48
stephen.darling20-Sep-10 21:48 
GeneralRe: what gets passed to what class?? [Modified] Pin
OriginalGriff20-Sep-10 21:59
mveOriginalGriff20-Sep-10 21:59 
GeneralRe: what gets passed to what class?? [Modified] Pin
stephen.darling20-Sep-10 22:07
stephen.darling20-Sep-10 22:07 
GeneralRe: what gets passed to what class?? [Modified] Pin
OriginalGriff21-Sep-10 2:10
mveOriginalGriff21-Sep-10 2:10 
QuestionFinding gap between Date ranges Pin
DJ24520-Sep-10 19:22
DJ24520-Sep-10 19:22 
AnswerRe: Finding gap between Date ranges Pin
Łukasz Nowakowski20-Sep-10 21:35
Łukasz Nowakowski20-Sep-10 21:35 
GeneralRe: Finding gap between Date ranges Pin
DJ24520-Sep-10 22:11
DJ24520-Sep-10 22:11 
GeneralRe: Finding gap between Date ranges Pin
Łukasz Nowakowski20-Sep-10 22:19
Łukasz Nowakowski20-Sep-10 22:19 
AnswerRe: Finding gap between Date ranges Pin
DJ24520-Sep-10 23:16
DJ24520-Sep-10 23:16 

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.