ArkM 1,090 Postaholic

What's a problem?

char getCursorChar()
{
    char c = '\0';
    CONSOLE_SCREEN_BUFFER_INFO con;
    HANDLE hcon = GetStdHandle(STD_OUTPUT_HANDLE);
    if (hcon != INVALID_HANDLE_VALUE &&
        GetConsoleScreenBufferInfo(hcon,&con)) 
    {
        DWORD read = 0;
        if (!ReadConsoleOutputCharacterA(hcon,&c,1,
            con.dwCursorPosition,&read) || read != 1
           )
           c = '\0';
    }
    return c;
}

It's so easy ;) and looks like a needless pastime...

Dimoris commented: It is unecessarilly complicated and braggard +0
ArkM 1,090 Postaholic

I should clarify here. Yes, Boost is unnecessary but so is cstdio in this context. But then so is the entire language of C++ or any other high-level language, for that matter.

Every library is there to make our life a little easier and so we don't have to re-invent the wheel everyday. Boost is a great example and should be put to use if someone finds it helpful.

Let's come back to the OP. Is it a question like how to delete file with Boost library? Or it was How can i delete the file in the middle of the program in C++? Correct me, please, if I'm wrong and it was Boost-oriented queston.
Otherwise let's discuss all great (and not only great) libraries where remove file functions exist. Let's consider how to use the Great Boost Library instead STL for streams, big num libraries instead of builtin operator +(POD,POD) and so on...
Keep it simpler ;)...

WaltP commented: Adding to the stupidity is not necessary. As you say, back to the OP. -3
ArkM 1,090 Postaholic

Can you explain why you have invented so strange manner to die for your top secret application? ;)...

ArkM 1,090 Postaholic

1. If you are using stdafx.h (in MS VC++), place all system includes in stdafx.h, not in your source modules.
2. Why #include "stdio.h" ? Must be #include <stdio.h> directive in stdafx.h.