在C#中能否直接调用WIN32API
2005-07-20 14:42
375 查看
要引用阿,you see
[DllImport("KERNEL32.DLL", EntryPoint="MoveFileW", SetLastError=true,
CharSet=CharSet.Unicode, ExactSpelling=true,
CallingConvention=CallingConvention.StdCall)]
public static extern bool MoveFile(String src, String dst);
public static void Main()
{
bool bl=MoveFile("y","u");
MessageBox.Show(bl.ToString());
}
[DllImport("KERNEL32.DLL", EntryPoint="MoveFileW", SetLastError=true,
CharSet=CharSet.Unicode, ExactSpelling=true,
CallingConvention=CallingConvention.StdCall)]
public static extern bool MoveFile(String src, String dst);
public static void Main()
{
bool bl=MoveFile("y","u");
MessageBox.Show(bl.ToString());
}
相关文章推荐
- C#可以直接调用的Win32API
- C#可以直接调用的Win32API(和VCL做的整理工作非常类似)
- C#可以直接调用的Win32API
- C#可以直接调用的Win32API
- C#可以直接调用的Win32API
- C# 直接调用vs 委托vs动态调用vs动态类型vs反射,最佳性能测试
- C#代码直接调用WCF服务
- 程序安装字体或直接调用非注册字体[c#]
- Javascript 直接调用服务器C#代码 ASP.NET Ajax实例
- c# 控制台程序调用直接运行一个新程序和隐藏自己的窗体(转)
- C# 直接调用非托管代码的方法
- C#调用WIN32API系列一列举可用COM端口
- c#中委托和直接函数调用用什么区别,好处和目的在哪?
- .Net/C# 应用程序直接读取本地 Cookies 文件(WinXP SP2 调用 API: InternetGetCookie 无果)
- CLR函数 SQL直接调用 C# DLL MSSQL DES 加解密
- c#调用 Win32Api之错误处理
- C#直接调用webBrowser JavaScript
- Javascript 直接调用服务器C#代码 ASP.NET Ajax实例
- .Net/C#应用程序直接读取本地Cookies文件(由于WinXPSP2调用API:InternetGetCookie无果)
- C# Web Service 不使用服务引用直接调用方法