registerkey()
好像可以,查查吧,我也没用过。

解决方案 »

  1.   

    void CMyView::OnEditCopy()
    {
      if ( !OpenClipboard() )
      {
        AfxMessageBox( "Cannot open the Clipboard" );
        return;
      }
      // Remove the current Clipboard contents
      if( !EmptyClipboard() )
      {
        AfxMessageBox( "Cannot empty the Clipboard" );
        return;
      }
      // ...
      // Get the currently selected data
      // ...
      // For the appropriate data formats...
      if ( ::SetClipboardData( CF_??, hData ) == NULL )
      {
        AfxMessageBox( "Unable to set Clipboard data" );
        CloseClipboard();
        return;
      }
      // ...
      CloseClipboard();
    }