C#中用了IntPtr类型,编译时提示说找不到类型或命名空间名称 

解决方案 »

  1.   

    命名空间:System
    [SerializableAttribute] 
    [ComVisibleAttribute(true)] 
    public struct IntPtr : ISerializable
      

  2.   

    错误 1 找不到类型或命名空间名称“Intptr”(是否缺少 using 指令或程序集引用?) 代码里用的是这个 方法 public Intptr FormNameAt(int x,int y) 
            {            IntPtr tem_hWnd;
                tem_Handle=(IntPtr)(WindowFromPoint(x.y));
                tem_hWnd = tem_Handle;
                while(tem_hWnd!=((IntPtr)0))
                {
                    tem_Handle = tem_hWnd;
                    tem_hWnd =GetParent(tem_hWnd);
                }
                return tem_handle;
            }一楼我二楼的试过了 ,不行