Re: Very strange problem using FWRITE() to write data to a binary file

From: Walter Roberson (roberson_at_ibd.nrc-cnrc.gc.ca)
Date: 02/08/05


Date: 8 Feb 2005 16:43:06 GMT

In article <1107880512.882536.191510@g14g2000cwa.googlegroups.com>,
 <leonecla@yahoo.it> wrote:
:I'm facing a very very strange problem with a very very simple C
:program...

:If I execute this code (compile with Visual Studio 6) and then open the
:"data_8bit.bin" file (inside the Visual Studio), it is displayed as a
:binary file, and I can see the data "07 07 07 17". It is correct.
:Now, if in the code above I assign to w the value 0x07070707 (instead
:of 0x17070707), execute the code and open the "data_8bit.bin", it
:contains no more binary data...
:The same happens with 0x99999999, for example.

This could be an artifact of whatever Visual Studio file viewer
facility you are using -- the viewer could be looking at the first
few bytes of the file to figure out what kind of file it is
and reacting differently for different sequences.

-- 
Disobey all self-referential sentences!


Relevant Pages

  • Re: Toplevel link-only project does not get linked during build
    ... note that T does NOT compile any source files. ... The problem is that when I execute "build solution", ... This happens identically in Visual Studio .net 2003 Professional Edition ...
    (microsoft.public.vc.ide_general)
  • Re: Cant find PInvoke DLL sqlceme30.dll (VS2005/SQLMobile)
    ... Visual Studio). ... Laxmi NRO, SQL Mobile, Microsoft Design Engineer ... Install CABs. ... > But when I execute the application on device I get "Can't find PInvoke DLL ...
    (microsoft.public.sqlserver.ce)
  • RE: Strange behavior when setting the icon of a window.
    ... /resource:icon1.ico command line parameter to csc embeds the icon in the ... This is why the EndsWithworked for csc and Visual Studio ... The program will execute properly from Visual Studio 2003 and at a command ...
    (microsoft.public.dotnet.languages.csharp)
  • demo dsw has nothing inside
    ... When I open the demo dsw with visual studio, ... so I cannot execute them. ... begin source code control ...
    (microsoft.public.vstudio.general)
  • Error Message
    ... I get this message "Error: Could not execute Main: The system cannot find the file specified." ... In searching this message on Microsoft's web site, it sends me to Microsoft Visual Studio 97 Service Pack 3, but as far as I know, I don't have Visual Studio on my computer?? ... Should I still try to download this service pack? ...
    (microsoft.public.windowsxp.security_admin)