#include<afxtempl.h>CMap<CString,LPCTSTR,CString,LPCTSTR>my_Map;CStringstrKey=_T("");CStringstrValue=_T("");my_Map.SetAt("1","hello");//添加元素CStringpLook;my_Map.Lookup("1",pLook);//查找元素ShowMessage(pLook.GetBuffer(pLook.GetLength()));intc=my_Map.GetCount();my_Map.RemoveAll();//删除所有元素boolre=my_Map.RemoveKey("1");//删除其中一个元素c=my_Map.GetCount();//获取元素个数