Click here to Skip to main content
15,896,359 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: Runtime error - incompatible iterator - why??? Pin
Philstix20-Dec-07 10:50
Philstix20-Dec-07 10:50 
GeneralRe: Runtime error - incompatible iterator - why??? Pin
Philstix20-Dec-07 10:53
Philstix20-Dec-07 10:53 
GeneralRe: Runtime error - incompatible iterator - why??? Pin
CPallini20-Dec-07 11:37
mveCPallini20-Dec-07 11:37 
QuestionRe: Runtime error - incompatible iterator - why??? Pin
Philstix20-Dec-07 15:34
Philstix20-Dec-07 15:34 
GeneralRe: Runtime error - incompatible iterator - why??? Pin
Stephen Hewitt20-Dec-07 15:36
Stephen Hewitt20-Dec-07 15:36 
GeneralRe: Runtime error - incompatible iterator - why??? Pin
Philstix20-Dec-07 17:28
Philstix20-Dec-07 17:28 
GeneralClass/struct declarations and bit patterns Pin
Anthony Appleyard20-Dec-07 10:43
Anthony Appleyard20-Dec-07 10:43 
GeneralRe: Class/struct declarations and bit patterns Pin
CPallini20-Dec-07 11:19
mveCPallini20-Dec-07 11:19 
You have not to worry about alignment, as far you are consistent on writing to and reading from file, for instance (error handling left to the reader)
struct BMPHeader bmphout;
// assign struct members
...
FILE * fpout = fopen("foo.bin", "wb");
fwrite( &bmphout, sizeof(bmphout),1, fpout);
fclose(fpout);

and then
struct BMPHeader bmphin;
FILE * fpin = fopen("foo.bin", "rb");
fread( &bmphin, sizeof(bmphin),1, fpin);
// Now bmphin contains exactly the same data of original bmphout
fclose(fpin);


Smile | :)
If the Lord God Almighty had consulted me before embarking upon the Creation, I would have recommended something simpler.
-- Alfonso the Wise, 13th Century King of Castile.

[my articles]


GeneralRe: Class/struct declarations and bit patterns Pin
Anthony Appleyard20-Dec-07 11:56
Anthony Appleyard20-Dec-07 11:56 
GeneralGood Luck! Pin
CPallini20-Dec-07 12:45
mveCPallini20-Dec-07 12:45 
GeneralRe: Class/struct declarations and bit patterns [modified] Pin
Mark Salsbery20-Dec-07 13:22
Mark Salsbery20-Dec-07 13:22 
GeneralAfter a picture is tranformed by GDI+, mouse cursor point problem Pin
followait20-Dec-07 5:57
followait20-Dec-07 5:57 
GeneralRe: After a picture is tranformed by GDI+, mouse cursor point problem Pin
CPallini20-Dec-07 10:16
mveCPallini20-Dec-07 10:16 
Generalplzz hlep Pin
coderwizard20-Dec-07 3:45
coderwizard20-Dec-07 3:45 
GeneralRe: plzz hlep Pin
George L. Jackson20-Dec-07 4:54
George L. Jackson20-Dec-07 4:54 
GeneralRe: plzz hlep Pin
coderwizard20-Dec-07 5:19
coderwizard20-Dec-07 5:19 
GeneralRe: plzz hlep Pin
fearless20-Dec-07 5:05
fearless20-Dec-07 5:05 
GeneralRe: plzz hlep Pin
Chris Losinger20-Dec-07 5:10
professionalChris Losinger20-Dec-07 5:10 
GeneralRe: plzz hlep Pin
leckey20-Dec-07 5:15
leckey20-Dec-07 5:15 
JokeRe: plzz hlep Pin
David Crow20-Dec-07 5:25
David Crow20-Dec-07 5:25 
GeneralRe: plzz hlep Pin
leckey20-Dec-07 6:38
leckey20-Dec-07 6:38 
JokeRe: plzz hlep Pin
CPallini20-Dec-07 5:21
mveCPallini20-Dec-07 5:21 
JokeRe: plzz hlep Pin
Hamid_RT20-Dec-07 5:27
Hamid_RT20-Dec-07 5:27 
GeneralRe: plzz hlep Pin
CPallini20-Dec-07 5:59
mveCPallini20-Dec-07 5:59 
GeneralRe: plzz hlep Pin
Hamid_RT20-Dec-07 6:45
Hamid_RT20-Dec-07 6:45 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.