16,548
社区成员




POSITION firstViewPos;
CView *pView;
firstViewPos=GetFirstViewPosition();
pView=GetNextView(firstViewPos);
pView->m_dlg[1]
就是获得的指针,是不是这样?pView=(CMonitorView*)(GetNextView(firstViewPos));
#include "stdafx.h"
#include "Monitor.h"
#include "MonitorDoc.h"
#include "MonitorView.h"
POSITION firstViewPos;
CMonitorView *pView;
firstViewPos=GetFirstViewPosition();
pView=GetNextView(firstViewPos);
POSITION firstViewPos;
CMyView *pView;
firstViewPos=GetFirstViewPosition();
pView=static<CMyView*>(GetNextView(firstViewPos));//这里要进行指针类型转换
POSITION firstViewPos;
CMyView *pView;
firstViewPos=GetFirstViewPosition();
pView=GetNextView(firstViewPos);