Delphi定时Showmessage事件
在Delphi中,调用Showmessage后,如何使弹出的对话框在一秒钟后自动关闭,而不用手动去点确定
1:用timer控件的函数
procedure TForm1.Timer1Timer(Sender: TObject);
var
AHandle: THandle;
begin
AHandle := FindWindow('TMessageForm',
PChar(Application.Title));
if AHandle > 0 then
SendMessage(AHandle,
WM_CLOSE, 0, 0);
end;
相关文档:
---
Delphi in a Unicode World Part I: What is Unicode, Why do you need
it, and How do you work with it in Delphi?
By: Nick
Hodges
原文链接:http://dn.codegear.com/article/38437
Abstract: This article discusses Unicode, how Delphi developers
can benefit from using Unicode, and ho ......
不论数组元素是什么类型,静态数组的局部变量总会在栈上分配。如果堆栈大小不够将会导致异常。下例暗藏着一个危险的bug
procedure stackover;
var
s:array [0..4100] of string[255];
begin
end;
delphi默认栈最大为$100000字节,上例中的栈上分配的大侠为256*4100>$10000。测试必然会出现异常Stack overf ......
原文参见: http://blog.csdn.net/ingener/archive/2007/12/22/1958535.aspx
关于Delphi中DLL封装对象的几种方法整理及体会
Delphi用DLL来封装对象的技术主要有三种:
用接口实现
用纯虚和抽象类方法实现
用类引用实现
前两种,都是在DLL中生成类实例;第3种通过在调用方生成实例。三种方法的共同局限如下: ......
把以前做过的项目总结一下!参加工作以来一共用三种不同语言实现了获得文件夹及其子文件信息。为了方便以后使用总结一下
air实现:
private function getfile(filelist:File):Array{
var list:Array = filelist.getDirectoryListing();
var count:uint=list.length;
......