Article View: borland.public.csharpbuilder.language.csharp
Article #190Re: Converting from Delphi (sets and streams)
From: David Clegg
Date: Sun, 29 Oct 2006 19:06
Date: Sun, 29 Oct 2006 19:06
21 lines
1635 bytes
1635 bytes
Marko Binic wrote: > Another problem I'm having is reading from a stream > (System.IO.FileStream). The BeginRead method takes a byte array, but > I need to read words (2 bytes) It sounds like you need the System.BitConverter class, in particular the BitConverter.ToUInt16(byte[] value, int startIndex) method. -- Cheers, David Clegg dclegg@gmail.com http://cc.borland.com/Author.aspx?ID=72299 QualityCentral. The best way to bug Borland about bugs. http://qc.borland.com "I'm not a bad guy! I work hard, and I love my kids. So why should I spend half my Sunday hearing about how I'm going to Hell?" - Homer Simpson
Technical Details
Message-ID:
<xn0et2x1d3ysvwy001@newsgroups.borland.com>Path:
arc1-ca.pugleaf.net!g2news2.google.com!news3.google.com!news2.volia.net!newsfeed01.sul.t-online.de!t-online.de!newsgroups.borland.com!not-for-mailReferences:
<45448666@newsgroups.borland.com>Show Full Headers
Complete Article Headers
X-Google-Thread: 1efe35,228682803dcaeb60
X-Google-Attributes: gid1efe35,public
X-Google-Language: ENGLISH,ASCII-7-bit
From: "David Clegg" <dclegg@gmail.com>
Subject: Re: Converting from Delphi (sets and streams)
Newsgroups: borland.public.csharpbuilder.language.csharp
References: <45448666@newsgroups.borland.com>
Organization: eBet Limited
User-Agent: XanaNews/1.18.1.3
X-Face: d0!4zUWIBj<CO5m0`=Vu"m.2)(~|1-4:I]5n5<OE<hv+kK)Z:n<h&MnW9t_{}>cw&gbV#f>mHS4h1mcw[cz:R#J,T;)w/($:2Vl5CQnFP(c\wmN0rSvn25.kmVpCmqb]gj7l9ZP+O4+a+P~L#]4s""Tx^zQ/N"#'/?lV?SHpdR\5(iNj.,I_YMfF=/_3.JWAs3
Message-ID: <xn0et2x1d3ysvwy001@newsgroups.borland.com>
X-Ref: newsgroups.borland.com ~XNS:00001216
NNTP-Posting-Host: 210.55.248.220
Date: 29 Oct 2006 12:06:29 -0700
X-Trace: newsgroups.borland.com 1162152389 210.55.248.220 (29 Oct 2006 12:06:29 -0700)
Lines: 21
Path: arc1-ca.pugleaf.net!g2news2.google.com!news3.google.com!news2.volia.net!newsfeed01.sul.t-online.de!t-online.de!newsgroups.borland.com!not-for-mail