TIP: Click on subject to list as thread! ANSI
echo: visual_basic
to: All
from: Gigamuxer donotspanme{at}sp
date: 2005-02-04 22:32:00
subject: Re: BInary file header parser.

J French wrote:
> On Thu, 03 Feb 2005 20:54:56 -0800, GigaMuxer
>  wrote:
>
>
>>Hello gang,
>>
>>I am preparing to build a VB app that will parse and decode a Binary
>>file. I'll explain the file structure bellow, but what I am looking for
>>is some source explaining how to do things like this fast on VB. This
>>would at least give me a head start.
>>
>>
>>The structure of the file is something like this:
>>
>>File can be split into 32 bytes(packets).
>>	All packets start w/ a sync of 0x47.
>>Each packet 3 bytes Header and 29 bytes data.
>>	Header:
>>		1st byte = sync
>>		2nd byte = identifier
>>		3rd byte = type(2 bits) , continuity(4 bits)and  version  (2 bits)
>>
>>There are 4 ways to decode the payload data and its specified by the
>>type value. This is errelevant as what I am trying to do now is to parse
>>the file.  These files can be as large as 5Mb.
>
>
> Open the file in Binary or Random mode and read the data into a UDT
>
> Since the records are always 32 bytes long you might as well use
> Random mode
>
> If you want to do it really fast then open the file in Binary mode,
> read the data in large chunks into a Byte Array
> - then use CopyMemory to push the bytes into a UDT

"Using CopyMemory to push the bytes into UDT" This is what I am looking
for.  Do you have a similar example(s)?

I truly appreciate it.


--- UseNet To RIME Gateway {at} 2/4/05 10:23:31 PM ---
* Origin: MoonDog BBS, Brooklyn,NY, 718 692-2498, 1:278/230 (1:278/230)
SEEN-BY: 633/267 270 5030/786
@PATH: 278/230 10/345 106/1 2000 633/267

SOURCE: echomail via fidonet.ozzmosis.com

Email questions or comments to sysop@ipingthereforeiam.com
All parts of this website painstakingly hand-crafted in the U.S.A.!
IPTIA BBS/MUD/Terminal/Game Server List, © 2025 IPTIA Consulting™.