摘要: 本文转载 http://blog.csdn.net/imbiz/article/details/5648682练习使用API。实现以下功能:1. 设定热键2. 检测当前活动窗口3. 向活动窗口发送信息4. 取消注册热键[c-sharp]view plaincopyusingSystem;usingSystem.Collections.Generic;usingSystem.ComponentModel;usingSystem.Data;usingSystem.Drawing;usingSystem.Linq;usingSystem.Text;usingSystem.Windows.Forms; 阅读全文
posted @ 2012-05-12 23:04 AYUI框架 阅读(697) 评论(0) 推荐(0) 编辑
摘要: SendKeys.Send 方法.NET Framework 4其他版本 .NET Framework 4.5.NET Framework 3.5.NET Framework 3.0.NET Framework 2.0向活动应用程序发送击键。命名空间: System.Windows.Forms程序集:System.Windows.Forms(在 System.Windows.Forms.dll 中)语法C#C++F#VB复制public static void Send( string keys)参数keys类型:System.String要发送的击键字符串。异常异常条件InvalidOper 阅读全文
posted @ 2012-05-12 23:01 AYUI框架 阅读(4905) 评论(0) 推荐(0) 编辑
摘要: 打开文件夹:1System.Diagnostics.Process.Start(FilePath);打开文件夹中某个文件:1System.Diagnostics.Process.Start(FilePath+"/"+FileName);打开文件夹并选中单个文件:1System.Diagnostics.Process.Start("Explorer","/select,"+ FilePath+"\\"+FileName);或1System.Diagnostics.Process.Start("Explore 阅读全文
posted @ 2012-05-12 21:54 AYUI框架 阅读(1330) 评论(2) 推荐(0) 编辑
摘要: 列出某数据库下的所有表SELECT TABLE_NAME FROM INFORMATION_SCHEMA.TABLES WHERE TABLE_TYPE = 'BASE TABLE'或者SELECT OBJECT_NAME (id) FROM sysobjects WHERE xtype = 'U' AND OBJECTPROPERTY (id, 'IsMSShipped') = 0或者使用SQLServer的存储过程“sp_tables”ADOX是ADO Extensions for DDL and Security,是微软对ADO技术的扩展, 阅读全文
posted @ 2012-05-12 18:35 AYUI框架 阅读(586) 评论(1) 推荐(1) 编辑