CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com

Search:

Type: Posts; User: Vectorprg

Search: Search took 0.01 seconds.

  1. Re: Writing and Reading Binary data in FORTRAN and C++

    Case1: using ReadFile()

    #define BUF_SIZE 5000
    BOOL bSuccess = FALSE;
    char Buf[BUF_SIZE];
    DWORD dwRead;
    for (;;)
    {
    bSuccess = ReadFile( V_hChildStd_OUT_Rd, Buf, BUF_SIZE, &dwRead, NULL);...
  2. Re: Writing and Reading Binary data in FORTRAN and C++

    Yes, If I write 12.54 to a binary file ( not console) with FORTRAN and then read that binary file with C++ it works fine. But in thatcase I am using ifstream to read the file and not using ReadFile()...
  3. Re: Writing and Reading Binary data in FORTRAN and C++

    I used exactly same code as you mentioned. But it does not give me the number. dwRead becomes equal to 6 which is less than size of a double number and does not make sense (sizeof(double) = 8)
    I...
  4. Re: Writing and Reading Binary data in FORTRAN and C++

    Thanks for the useful information. I think I did a similar case before:
    If I write 12.54 to a binary file ( not console) with FORTRAN and then read that binary file with C++ it works fine. But in...
  5. Re: Writing and Reading Binary data in FORTRAN and C++

    As you know there are two formats: ASCII format (which is readable by human) and Binary format (which is computer language). I am now working with ASCII format which means I write the actual number...
  6. Writing and Reading Binary data in FORTRAN and C++

    I am writing a double number in Binary format to the console of program A (in FORTRAN) with the following code:


    REAL*8 A
    A = 12.54
    INQUIRE(6, name = xstring)
    OPEN(1,file=xstring,...
Results 1 to 6 of 6





Click Here to Expand Forum to Full Width

Featured