本帖最后由 znjcx 于 2009-09-12 16:36:11 编辑

解决方案 »

  1.   

    printf("%d %d", (int)ite->second.UniqueProcess, (int)ite->second.UniqueThread);
      

  2.   

    [code=C/C++]
    #include <hash_map>
    #include <stdio.h>
    using namespace std;
    using namespace stdext;
    int main(void)
    {
        hash_map<int, PORT_MESSAGE> hm;
        hash_map<int, PORT_MESSAGE>::const_iterator ite;
        PORT_MESSAGE ci;
        
        for (int i = 0, j = 100; i < 100; i++,j--)
        {
            memset(&ci, i, sizeof ci);
            hm[i] = ci;
            ite = hm.find(i);
           printf("%d %d", (int)ite->second.UniqueProcess, (int)ite->second.UniqueThread);
        }
        return 0;
    }
    //我这样写不行啊,编译不过,请指点
    code]
      

  3.   

    看错了,不好意思
    printf("%d %d", (int)ite->second.ClientId.UniqueProcess, (int)ite->second.ClientId.UniqueThread); 
      

  4.   

    解决了,ite->second.ClientId.UniquePorcess
    这样就可以了,结贴