binary files and user defined data types 
Author Message
 binary files and user defined data types

Code a UDT for your header.
Open file for binary...
Use Get to read the file

Quote:
> Hi All,

>  re: reading and writing to binary files.

> Has anyone attempted to read header information from a binary file in
> VB. If the details of the header information (of say an image(eg tif)
> file) are known(where certain information is stored (eg bytes 110
> through 125 etc) and what exactly is stored), is it possible to create a
> data type to read that information into that type. Any details could
> then be changed and written back to the header and the image could be
> viewed as normal. I'm not that interested in the 'display' of the image
> per se only the information that's stored in the header, where and can
> it be changed fairly easily in VB.

> Any information would be useful, using any sort of image data (or
> reading binary files).

> regards,

> Michael



Fri, 22 Feb 2002 03:00:00 GMT  
 binary files and user defined data types
Hi All,

 re: reading and writing to binary files.

Has anyone attempted to read header information from a binary file in
VB. If the details of the header information (of say an image(eg tif)
file) are known(where certain information is stored (eg bytes 110
through 125 etc) and what exactly is stored), is it possible to create a
data type to read that information into that type. Any details could
then be changed and written back to the header and the image could be
viewed as normal. I'm not that interested in the 'display' of the image
per se only the information that's stored in the header, where and can
it be changed fairly easily in VB.

Any information would be useful, using any sort of image data (or
reading binary files).

regards,

Michael



Sat, 23 Feb 2002 03:00:00 GMT  
 binary files and user defined data types
You can use Get and Put to read/write data to any part of a file. If you
know the precise format of the header then you can create a UDT with longs,
fixed length strings etc. Alternativey, you can create a Byte array equal in
length to the part of the file you are interested in.

Mike


Quote:
> Hi All,

>  re: reading and writing to binary files.

> Has anyone attempted to read header information from a binary file in
> VB. If the details of the header information (of say an image(eg tif)
> file) are known(where certain information is stored (eg bytes 110
> through 125 etc) and what exactly is stored), is it possible to create a
> data type to read that information into that type. Any details could
> then be changed and written back to the header and the image could be
> viewed as normal. I'm not that interested in the 'display' of the image
> per se only the information that's stored in the header, where and can
> it be changed fairly easily in VB.

> Any information would be useful, using any sort of image data (or
> reading binary files).

> regards,

> Michael



Sat, 23 Feb 2002 03:00:00 GMT  
 binary files and user defined data types
Hi All,

 re: reading and writing to binary files.

Has anyone attempted to read header information from a binary file in
VB. If the details of the header information (of say an image(eg tif)
file) are known(where certain information is stored (eg bytes 110
through 125 etc) and what exactly is stored), is it possible to create a
data type to read that information into that type. Any details could
then be changed and written back to the header and the image could be
viewed as normal. I'm not that interested in the 'display' of the image
per se only the information that's stored in the header, where and can
it be changed fairly easily in VB.

Any information would be useful, using any sort of image data (or
reading binary files).

regards,

Michael



Sat, 23 Feb 2002 03:00:00 GMT  
 
 [ 4 post ] 

 Relevant Pages 

1. Q: variant data type with user defined data type

2. Compile error: User-defined data type not defined!

3. Type mismatch on user defined data type

4. User Control - User-defined type not defined

5. VB4: Help: data-alignment in user defined data types

6. Help: data-alignment in user defined data types

7. reading binary data into a user defined variable (structure)

8. Passing Array or a user defined data type as a parameter to a storedprocedure in Oracle

9. HELP user defined data types

10. visual basic user defined data types

11. Assigning recordset recodset to a user Defined Data Type

12. Sorting arrays of user defined data type

 

 
Powered by phpBB® Forum Software