Switch to a specific CDockablePane (in a tabbed format )

Terkunci Switch to a specific CDockablePane (in a tabbed format )

  • 19 April 2012 11:55
     
     

    Dear all,

    I am migrating my MFC MDI application to use the new MFC Feature Pack. I am using many CDockablePane objects in my application, to allow the user to dock the panes wherever s/he wants. This allows the user to dock them in a tabbed format.

    Sometimes, I want to programatically show a certain pane on top of others to draw attention to it. Is there a way to automatically switch to a specific pane when it is already docked with other panes in a tabbed format?

    Please advise.
    Thank you :)

Semua Balasan

  • 19 April 2012 12:16
     
     Jawab Memiliki Kode

    Give CDockablePane::ShowPane a try :

    m_wndPane.ShowPane(TRUE, FALSE, TRUE);

    • Ditandai sebagai Jawaban oleh Douda123 19 April 2012 14:06
    •  
  • 19 April 2012 12:30
     
     

    Thank you Pierre,

    I already tried ShowPane but unfortunately it does not set the CDockablePane as active in a tabbed control. It just shows it if it was previously closed by the user.

    Thank you.

  • 19 April 2012 12:47
     
     
    > unfortunately it does not set the CDockablePane as active in a tabbed control
     
    What do you mean?
    ShowPane shows the pane and gives focus to it.
    What do you expect?
     
  • 19 April 2012 14:06
     
     

    Dear Pierre,

    It works now.. I just had something wrong in my code. Sorry for that. Thanks for your help!