[DllImport("user32.dll", EntryPoint="CallWindowProc")]
public static extern int CallWindowProc (
int lpPrevWndFunc,
int hWnd,
int Msg,
int wParam,
int lParam
);
public static extern int CallWindowProc (
int lpPrevWndFunc,
int hWnd,
int Msg,
int wParam,
int lParam
);
解决方案 »
- C#开始事务后循环比较插入数据问题
- listview doubleclick事件的使用
- 面试答疑: 面向对象 与 面向过程 他们的开发方式都是怎么样的啊
- winform如何在page_load初始化中触发button按钮事件
- contextmenustrip定位问题
- 如何在Web Service中使用Hashtable?江湖救急。
- visual studio出问题了,不知道具体怎么引起的
- 使用RichTextBox控件的LoadFile方法打开文件时,提示"无效文件格式"
- 一个关于线程的小疑问?
- C#控件中如何获得属性变化前的时机?(内详)
- 大哥,帮我把vb代码转换成c# 一下好么 ?急
- C#如何画图标啊
CallWindowProc& 中的 “&”代表什么意思哦 ?
http://topic.csdn.net/u/20080218/11/88649ad6-c946-46f8-9546-926a9c583376.html
user32是Windows标准库,这样的api随便找,有现成的C#版,不用费劲翻译。直接搜索:“C# CallWindowProc”
当然更恰当的搜索是:“C# CallWindowProc DllImport static extern”
[DllImport("User32.dll")]
private static extern IntPtr CallWindowProc(IntPtr prevWndFunc, IntPtr hWnd, int iMsg, IntPtr wParam, IntPtr lParam);
&在VB中标识long类型按原来的意思翻译出来是这个
[DllImport("user32")]
private static extern long CallWindowProc(long lpPrevWndFunc, long hWnd, long Msg, long wParam, long lParam);
不过long是64位,IntPtr才是32位。是否能正常调用,自己通过测试验证。
Public Declare Function GdiplusStartup Lib "GdiPlus" (token As Long, inputbuf As GdiplusStartupInput, Optional ByVal outputbuf As Long = 0) As GpStatus