Click here to Skip to main content
15,895,746 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
AnswerRe: how can i open a file and search a specific name on it Pin
Hamid_RT1-Dec-07 8:25
Hamid_RT1-Dec-07 8:25 
QuestionWho ever used CJ60Lib? Pin
followait30-Nov-07 17:43
followait30-Nov-07 17:43 
AnswerRe: Who ever used CJ60Lib? Pin
Hamid_RT30-Nov-07 19:12
Hamid_RT30-Nov-07 19:12 
GeneralRe: Who ever used CJ60Lib? Pin
followait30-Nov-07 19:25
followait30-Nov-07 19:25 
GeneralRe: Who ever used CJ60Lib? Pin
Hamid_RT30-Nov-07 19:44
Hamid_RT30-Nov-07 19:44 
GeneralRe: Who ever used CJ60Lib? Pin
followait1-Dec-07 4:39
followait1-Dec-07 4:39 
GeneralRe: Who ever used CJ60Lib? Pin
Hamid_RT1-Dec-07 8:25
Hamid_RT1-Dec-07 8:25 
QuestionContext Menu (Determine HWnd) Pin
Jeffrey Walton30-Nov-07 16:46
Jeffrey Walton30-Nov-07 16:46 
Hi All,

After inserting a item is Explorer's shell, one must call DrawMenuItem( hWnd ) to to update the menu. However, the code which inserts the menu item does not receive an hwnd. Any ideas how to obtain the hWnd from an hMenu? Below is the context which DrawMenuBar() would have.

Jeff

HRESULT CTest::QueryContextMenu( HMENU hmenu, UINT uMenuIndex,
                       UINT uidFirstCmd, UINT uidLastCmd, UINT uFlags )
{
    uidLastCmd; // Suppress Warning C4100
    
    // If the flags include CMF_DEFAULTONLY then we shouldn't do anything.
    if( uFlags & CMF_DEFAULTONLY )
        { return MAKE_HRESULT ( SEVERITY_SUCCESS, FACILITY_NULL, 0 ); }

    // Count exist somewhere...
    if( m_count > 1 )
    {
        InsertMenu( hmenu, uMenuIndex, MF_BYPOSITION,
                    uidFirstCmd, _T("String 1") );
    }
    else
    {
        InsertMenu( hmenu, uMenuIndex, MF_BYPOSITION,
                    uidFirstCmd, _T("String 2") );
    }

    HWND hwnd = null;
    DrawMenuBar( hwnd );

    return MAKE_HRESULT( SEVERITY_SUCCESS, FACILITY_NULL, 1 );
}

GeneralRe: Context Menu (Determine HWnd) Pin
James R. Twine10-Mar-08 4:58
James R. Twine10-Mar-08 4:58 
QuestionSynchronising Computerson a Small Network Pin
Bram van Kampen30-Nov-07 15:23
Bram van Kampen30-Nov-07 15:23 
GeneralRe: Synchronising Computerson a Small Network Pin
James R. Twine10-Mar-08 5:02
James R. Twine10-Mar-08 5:02 
GeneralRe: Synchronising Computerson a Small Network Pin
Bram van Kampen11-Mar-08 12:28
Bram van Kampen11-Mar-08 12:28 
GeneralRe: Synchronising Computerson a Small Network Pin
James R. Twine11-Mar-08 14:22
James R. Twine11-Mar-08 14:22 
Questionkey - information - map Pin
james_dixon_200830-Nov-07 15:11
james_dixon_200830-Nov-07 15:11 
QuestionCreating a CPropertySheet-based app Pin
Dr Dan30-Nov-07 11:32
Dr Dan30-Nov-07 11:32 
QuestionRe: Creating a CPropertySheet-based app Pin
Mark Salsbery30-Nov-07 12:17
Mark Salsbery30-Nov-07 12:17 
AnswerRe: Creating a CPropertySheet-based app Pin
Dr Dan30-Nov-07 22:34
Dr Dan30-Nov-07 22:34 
AnswerRe: Creating a CPropertySheet-based app Pin
Moak30-Nov-07 14:09
Moak30-Nov-07 14:09 
AnswerRe: Creating a CPropertySheet-based app Pin
Alain Rist30-Nov-07 21:50
Alain Rist30-Nov-07 21:50 
QuestionFailed to create empty document Pin
RomTibi30-Nov-07 10:12
RomTibi30-Nov-07 10:12 
QuestionRe: Failed to create empty document Pin
David Crow30-Nov-07 10:45
David Crow30-Nov-07 10:45 
AnswerRe: Failed to create empty document Pin
RomTibi30-Nov-07 19:45
RomTibi30-Nov-07 19:45 
QuestionSet up dimensions Pin
Schehaider_Aymen30-Nov-07 10:00
Schehaider_Aymen30-Nov-07 10:00 
AnswerRe: Set up dimensions Pin
followait30-Nov-07 18:26
followait30-Nov-07 18:26 
GeneralRe: Set up dimensions [modified] Pin
Schehaider_Aymen30-Nov-07 22:18
Schehaider_Aymen30-Nov-07 22:18 

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.