Click here to Skip to main content
15,905,414 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: How to detect Internet connection on machine? Pin
baerten11-Sep-07 3:38
baerten11-Sep-07 3:38 
GeneralRe: How to detect Internet connection on machine? Pin
bob1697211-Sep-07 17:06
bob1697211-Sep-07 17:06 
GeneralRe: How to detect Internet connection on machine? Pin
jhwurmbach11-Sep-07 4:07
jhwurmbach11-Sep-07 4:07 
GeneralRe: How to detect Internet connection on machine? Pin
David Crow11-Sep-07 4:25
David Crow11-Sep-07 4:25 
AnswerRe: How to detect Internet connection on machine? Pin
bob1697211-Sep-07 2:05
bob1697211-Sep-07 2:05 
AnswerRe: How to detect Internet connection on machine? Pin
bob1697211-Sep-07 2:08
bob1697211-Sep-07 2:08 
AnswerRe: How to detect Internet connection on machine? Pin
David Crow11-Sep-07 3:13
David Crow11-Sep-07 3:13 
Questionmap file with 0 size Pin
Vinod CS10-Sep-07 22:46
Vinod CS10-Sep-07 22:46 
Hi,
My code tries to map a file with createFileMapping(). The Problem is
when the file is not present, this function fails with GetLastErr saying
"The Volume for a file has been externally altered". I am attaching code sample:

HANDLE hCreateFile = CreateFile(  _T("E:\\size0.txt"), // file name with path <br />
                                       GENERIC_READ | GENERIC_WRITE, // Access mode<br />
                                       FILE_SHARE_READ, // Sharing mode<br />
                                       NULL,            // Security Attributes     <br />
                                       OPEN_ALWAYS ,  //   How to create<br />
                                       FILE_ATTRIBUTE_NORMAL, // File attributes<br />
                                       NULL                 // Handle to template file<br />
                                       );<br />
               <br />
        if( INVALID_HANDLE_VALUE == hCreateFile )<br />
        { err handling       }<br />
        // 2. Create a FILE mapping object<br />
        HANDLE hFileMap = CreateFileMapping( hCreateFile, // handle to the opened file <br />
                                             NULL,        // security attributes <br />
                                             PAGE_READWRITE, // protection<br />
                                             0,              // high-order DWORD of size<br />
                                             0,             // low-order DWORD of size<br />
                                             NULL           // mapping object name<br />
                                             );<br />
        <br />
        if( NULL == hFileMap ) // this return NULL when file size is 0.<br />
        { errHandling() }


How can I map a file with 0 Size? pls help

regds,
vinod
AnswerRe: map file with 0 size Pin
Naveen10-Sep-07 23:13
Naveen10-Sep-07 23:13 
GeneralRe: map file with 0 size Pin
Vinod CS11-Sep-07 17:42
Vinod CS11-Sep-07 17:42 
AnswerRe: map file with 0 size Pin
Sameerkumar Namdeo10-Sep-07 23:30
Sameerkumar Namdeo10-Sep-07 23:30 
GeneralRe: map file with 0 size [modified] Pin
Vinod CS11-Sep-07 17:44
Vinod CS11-Sep-07 17:44 
QuestionPNG Alpha blending/channel in VC++ 6.0? Pin
StarMeteor10-Sep-07 22:33
StarMeteor10-Sep-07 22:33 
AnswerRe: PNG Alpha blending/channel in VC++ 6.0? Pin
Mark Salsbery11-Sep-07 8:04
Mark Salsbery11-Sep-07 8:04 
GeneralRe: PNG Alpha blending/channel in VC++ 6.0? Pin
StarMeteor11-Sep-07 16:45
StarMeteor11-Sep-07 16:45 
GeneralRe: PNG Alpha blending/channel in VC++ 6.0? Pin
Mark Salsbery12-Sep-07 6:17
Mark Salsbery12-Sep-07 6:17 
GeneralRe: PNG Alpha blending/channel in VC++ 6.0? Pin
StarMeteor12-Sep-07 17:21
StarMeteor12-Sep-07 17:21 
GeneralRe: PNG Alpha blending/channel in VC++ 6.0? Pin
Mark Salsbery13-Sep-07 5:24
Mark Salsbery13-Sep-07 5:24 
Questiondont replace the ok button coding in that ok button e want enter coding Pin
yadahav10-Sep-07 22:02
yadahav10-Sep-07 22:02 
AnswerRe: dont replace the ok button coding in that ok button e want enter coding Pin
Cedric Moonen10-Sep-07 22:27
Cedric Moonen10-Sep-07 22:27 
QuestionStoping thread.... Pin
neha.agarwal2710-Sep-07 22:01
neha.agarwal2710-Sep-07 22:01 
AnswerRe: Stoping thread.... Pin
Cedric Moonen10-Sep-07 22:04
Cedric Moonen10-Sep-07 22:04 
AnswerRe: Stoping thread.... Pin
Sreedhar DV10-Sep-07 22:11
Sreedhar DV10-Sep-07 22:11 
AnswerRe: Stoping thread.... Pin
David Crow11-Sep-07 3:15
David Crow11-Sep-07 3:15 
QuestionHow to create enter botton in mfc? Pin
yadahav10-Sep-07 21:34
yadahav10-Sep-07 21:34 

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.