Click here to Skip to main content
15,910,211 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralCFile::Read() : Giving zero bytes read Pin
Ardhendu_diva28-Sep-04 0:09
Ardhendu_diva28-Sep-04 0:09 
GeneralRe: CFile::Read() : Giving zero bytes read Pin
22491728-Sep-04 1:03
22491728-Sep-04 1:03 
GeneralRe: CFile::Read() : Giving zero bytes read Pin
ardhendu12328-Sep-04 1:46
ardhendu12328-Sep-04 1:46 
GeneralRe: CFile::Read() : Giving zero bytes read Pin
22491728-Sep-04 17:23
22491728-Sep-04 17:23 
GeneralRe: CFile::Read() : Giving zero bytes read Pin
Antony M Kancidrowski28-Sep-04 1:50
Antony M Kancidrowski28-Sep-04 1:50 
GeneralRe: CFile::Read() : Giving zero bytes read Pin
ardhendu12328-Sep-04 1:57
ardhendu12328-Sep-04 1:57 
GeneralRe: CFile::Read() : Giving zero bytes read Pin
Antony M Kancidrowski28-Sep-04 2:22
Antony M Kancidrowski28-Sep-04 2:22 
GeneralRe: CFile::Read() : Giving zero bytes read Pin
vcplusplus28-Sep-04 4:07
vcplusplus28-Sep-04 4:07 
It is hard for us to help you, if you do not tell us whether there is an error when you use CFile::Read(...).

DWORD dwStart = pFile->GetPosition();
DWORD dwBitsSize = pFile->GetLength();
printf("\n Size %d\n", dwBitsSize);
BITMAPFILEHEADER fileHeader;
memset(&fileHeader, 0, sizeof(fileHeader));
TRY
{
    UINT count = pFile->Read(&fileHeader, sizeof(fileHeader));
    printf("\nByte Read %d %d\n", count, pFile->GetPosition());
}
CATCH(CFileException, e)
{
    printf("\nCFileException %d\n", e->m_cause);
}
END_CATCH

GeneralRe: CFile::Read() : Giving zero bytes read Pin
David Crow28-Sep-04 4:11
David Crow28-Sep-04 4:11 
GeneralCan't prevent new window opening! Pin
henryfonda27-Sep-04 23:26
henryfonda27-Sep-04 23:26 
GeneralRe: Can't prevent new window opening! Pin
agentnem28-Sep-04 10:00
agentnem28-Sep-04 10:00 
GeneralRe: Can't prevent new window opening! Pin
henryfonda28-Sep-04 14:25
henryfonda28-Sep-04 14:25 
GeneralRe: Can't prevent new window opening! Pin
Scott H. Settlemier28-Sep-04 14:55
Scott H. Settlemier28-Sep-04 14:55 
GeneralRe: Can't prevent new window opening! Pin
henryfonda28-Sep-04 21:04
henryfonda28-Sep-04 21:04 
GeneralHowto change the font of a CStatic text Pin
anderslundsgard27-Sep-04 22:26
anderslundsgard27-Sep-04 22:26 
GeneralRe: Howto change the font of a CStatic text Pin
Manfred Staiger27-Sep-04 23:43
Manfred Staiger27-Sep-04 23:43 
GeneralRe: Howto change the font of a CStatic text Pin
anderslundsgard27-Sep-04 23:52
anderslundsgard27-Sep-04 23:52 
GeneralRe: Howto change the font of a CStatic text Pin
Manfred Staiger28-Sep-04 0:14
Manfred Staiger28-Sep-04 0:14 
QuestionHow can I get the lpClassName? Pin
Guoguor27-Sep-04 21:36
Guoguor27-Sep-04 21:36 
AnswerRe: How can I get the lpClassName? Pin
22491728-Sep-04 0:34
22491728-Sep-04 0:34 
AnswerRe: How can I get the lpClassName? Pin
cmk28-Sep-04 9:39
cmk28-Sep-04 9:39 
QuestionAbout painting on screen? Pin
Zero_One_ADO27-Sep-04 20:59
Zero_One_ADO27-Sep-04 20:59 
AnswerRe: About painting on screen? Pin
Aamir Butt28-Sep-04 1:37
Aamir Butt28-Sep-04 1:37 
GeneralIE Hooking Pin
TPN27-Sep-04 20:57
TPN27-Sep-04 20:57 
GeneralRe: IE Hooking Pin
22491727-Sep-04 21:12
22491727-Sep-04 21:12 

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.