reading binary with freepascal 
Author Message
 reading binary with freepascal

Hi,

I am reading a binary format perfectly with Turbo Pascal 5.5.

There is no problem indeed but when I run the same code with freepascal. The
output (which is an ASCII text file) is totally wrong. I can see some
coloums ar ok but it is obvious that it does not work.

Where should I start to look for the problem? What is the first topic to
focus on that?

TIA



Tue, 22 Nov 2005 01:49:41 GMT  
 reading binary with freepascal

Quote:

> Hi,

> I am reading a binary format perfectly with Turbo Pascal 5.5.

> There is no problem indeed but when I run the same code with freepascal. The
> output (which is an ASCII text file) is totally wrong. I can see some
> coloums ar ok but it is obvious that it does not work.

Do you use FPC in strict TP mode?  (-So) ?
Do you write pointers or other types that are pointers internally to file?
 Those are still 4 bytes.

Quote:
> Where should I start to look for the problem? What is the first topic to
> focus on that?

The above two.


Tue, 22 Nov 2005 03:41:10 GMT  
 reading binary with freepascal
well, I was using FPE and from the project options I check the box
"compitible with TP7". Now it works perfect :)))

Thank you...



Quote:

> > Hi,

> > I am reading a binary format perfectly with Turbo Pascal 5.5.

> > There is no problem indeed but when I run the same code with freepascal.
The
> > output (which is an ASCII text file) is totally wrong. I can see some
> > coloums ar ok but it is obvious that it does not work.

> Do you use FPC in strict TP mode?  (-So) ?
> Do you write pointers or other types that are pointers internally to file?
>  Those are still 4 bytes.

> > Where should I start to look for the problem? What is the first topic to
> > focus on that?

> The above two.



Tue, 22 Nov 2005 04:14:34 GMT  
 
 [ 3 post ] 

 Relevant Pages 

1. Can FreePascal generate flat binary files?

2. How to do fast sequential binary read ?

3. problems reading binary file, and outputting to screen.

4. reading binary file and outputting to standard output (screen)

5. Binary field read/write

6. Can Excel read a Pascal binary file?

7. I need to read a binary file

8. Reading Pascal-generated PACKED binary w/ C program

9. Reading binary files in pascal

10. Reading binary files in PASCAL ??

11. problem reading 4-byte reals from binary file

12. Saving Binary Data to a Paradox Binary Field via Code

 

 
Powered by phpBB® Forum Software