首页 诗词 字典 板报 句子 名言 友答 励志 学校 网站地图
当前位置: 首页 > 教程频道 > 开发语言 > VC/MFC >

怎么用MFC做一个demo,显示树。

2013-10-10 
如何用MFC做一个demo,显示树。急急急!下面两个结构体,第一个结构体里 depId与第二个结构体 depId一样,所以

如何用MFC做一个demo,显示树。急急急!
下面两个结构体,第一个结构体里 depId与第二个结构体 depId一样,所以把第二个结构体挂到第一个结构体 depId下。
class OBSEVICER_API  DepTreeEntity {
public:
//成员变量
int  depId;
char depName[80];
//string depName;
int  parentId;
char fullPath[80];
int  nodeOrder;
int  onlineChannelCount;
int  offlineChannelCount;

//成员函数
void InitTree(); 
BOOL OB_GetDepTreeEntityList(string arg0 , string arg1, std::list<DepTreeEntity *> *listTree);

};

class  OBSEVICER_API VideoInChannelInfo
{
public:
//成员变量
int   id;
char  fdId[80];
int   channelId;
int   fdType;
int   channelType;
char  idExt[80];
char  channelName[80];
char  channelLocation[80];
char  longitude[80];
char  latitude[80];
int   videoFormat;
int   videoResolution;
int   frameRate;
int   channelState;
int   recoardState;
char  centerStoreAreaGroup[80];
int   directNum;
int   liveNeedRelay;
int   recordNeedRelay;
int   depId;
int   orgId;
int   isOnline;

//成员函数
void InitChannel();
BOOL OB_GetDepVideoInChannleArray (string arg0,int arg1,list<VideoInChannelInfo *> *listChannel);
};
这是我DLL里函数实现初始化部分:
OBSEVICER_API void DepTreeEntity::InitTree()
{
depId = 8;
strcpy(depName,"spy");
parentId = 3;
strcpy(fullPath,"sing");
nodeOrder = 16;
onlineChannelCount =18;
offlineChannelCount =2;

}

OBSEVICER_API void VideoInChannelInfo::InitChannel()
{
id = 2;
strcpy(fdId,"td");
channelId = 3;
fdType = 4;
channelType = 5;
strcpy(idExt,"ts");
strcpy(channelName,"tk");
strcpy(channelLocation,"tt");
strcpy(longitude,"tl");
strcpy(latitude,"ti");
videoFormat = 6;
videoResolution = 7;
frameRate = 8;
channelState = 9;
recoardState = 10;
strcpy(centerStoreAreaGroup,"tw");
directNum = 11;
liveNeedRelay =12;
recordNeedRelay = 13;
depId = 14;
orgId = 15;
isOnline = 16;
}
请高手帮忙,怎么写给个思路或者代码让我参考
[解决办法]
您好
我是本版版主
此帖已多日无人关注
请您及时结帖
如您认为问题没有解决可按无满意结帖处理
另外本版设置了疑难问题汇总帖
并已在版面置顶
相关规定其帖子中有说明
您可以根据规定提交您帖子的链接
如您目前不想结帖只需回帖说明
我们会删除此结帖通知

见此回复三日内无回应
我们将强制结帖
相关规定详见界面界面版关于版主结帖工作的具体办法

热点排行