Поделиться через


CWinFormsView::CWinFormsView

Constructs a CWinFormsView object.

CWinFormsView(
   System::Type^ pManagedViewType
);

Параметры

  • pManagedViewType
    A pointer to the data type of the Windows Forms user control. For more information, see System.Type.

Пример

In the following example, the CUserView class inherits from CWinFormsView and passes the type of UserControl1 to the CWinFormsView constructor. UserControl1 is a custom-built control in ControlLibrary1.dll.

class CMyView : public CWinFormsView
IMPLEMENT_DYNCREATE(CMyView, CWinFormsView)

BEGIN_MESSAGE_MAP(CMyView, CWinFormsView)
END_MESSAGE_MAP()

CMyView::CMyView()
   : CWinFormsView(ControlLibrary1::UserControl1::typeid)
{
}

Требования

Header: afxwinforms.h

См. также

Основные понятия

CWinFormsView Class

CWinFormsView Members