Indy FTP 警告:Only one TIdAntiFreeze can be active in an application
> Should I use a AntiFreeze component on every form I have a TIdTCPClient
> component? Or is one enough to handle the whole Application?
One is enough. According to the Indy help file,
--------
Only one TIdAntiFreeze can be active in an application. If another
instance already exists, an exception is raised.
--------
Note that if you have multiple TIdTCPClient objects connected at the
same time, and you call ReadXXX twice or more often (e. g. on a button
click event) in the main thread context, then the last called ReadXXX
will return first, blocking the other ReadXXX requests even if they
could return data. This is because of the nature of the AntiFreeze
mechanism.
To avoid this effect, use a dedicated reader thread for each connection
instead of AntiFreeze. There is a TIdTCPClient descendant with its own
reader thread, firing an event when data arrive, at
http://come.to/delphi-bits .
-Michael
TIdAntiFreeze = class(TIdAntiFreezeBase)
Only one TIdAntiFreeze can be active in an application. If another instance already exists, an exception is raised. TIdAntiFreezeBase uses the global variable GAntiFreeze, declared in the TIdAntiFreezeBase unit, to determine if another instance has already been created.
Note: GAntiFreeze is not assigned if an instance is added in the form designer (during design time).
Note: The TIdAntiFreeze.pas unit must NOT appear in the uses clause of any Indy or descendant unit. This unit is linked in an application when the component is placed on a Form. This is done to preserve isolation from the Forms.pas and QForms.pas units.
procedure Process; override;
Note: Due to the differences in message dispatching, Process does not use or inspect ApplicationHasPriority on the Linux Platform; Process simply calls Application.ProcessMessages.
Note: The TIdAntiFreeze.pas unit must NOT appear in the uses clause of any Indy or descendant unit. This unit is linked in an application when the component is placed on a Form. This is done to preserve isolation from the FORMS.PAS and QForms.pas units.
Indy FTP 警告:Only one TIdAntiFreeze can be active in an application的更多相关文章
- ftp 229
在sels10机器上登入ftp输入用户名和密码之后再ls发现出现如下问题Entering Extended Passive Mode ftp> ls229 Entering Extended P ...
- Different between Telnet/SSH/FTP
http://www.differencebetween.net/category/technology/protocols-formats/ Telnet vs SSH Secure Shell, ...
- ftp的主动模式active mode和被动模式 passive mode的配置和区别
ftp的主动模式active mode和被动模式 passive mode的配置和区别 2017年05月08日 17:47:16 阅读数:21768 本文主要记录的是在linux上的区别,弄了一整天才 ...
- iOS警告框和操作表
应用如何与用户交流呢? 警告框(AlertView)和操作表(ActionSheet)就是为此而设计的. 本文案例的原型草图如图3-48所示,其中有两个按钮“Test警告框”和“Test操作表”,点击 ...
- IdTcpClient简单示例
procedure TForm1.btnHttpGetClick(Sender: TObject); begin idtcpclnt1.Host := '192.168.10.88'; idtcpcl ...
- Codeigniter
最近准备接手改进一个别人用Codeigniter写的项目,虽然之前也有用过CI,但是是完全按着自己的意思写的,没按CI的一些套路.用在公众的项目,最好还是按框架规范来,所以还是总结一下,免得以后别人再 ...
- 总结Codeigniter的一些优秀特性
总结Codeigniter的一些优秀特性 近期准备接手改进一个别人用Codeigniter写的项目.尽管之前也实用过CI,可是是全然按着自己的意思写的,没按CI的一些套路.用在公众的项目,不妨按框架规 ...
- Codeigniter的一些优秀实践
最近准备接手改进一个别人用Codeigniter写的项目,虽然之前也有用过CI,但是是完全按着自己的意思写的,没按CI的一些套路.用在公众的项目,最好还是按框架规范来,所以还是总结一下,免得以后别人再 ...
- 转:Delphi 6 实用函数
来自: daocaoren0824, 时间: -- ::, ID: 再给你一份 程序员实用函数 {▎▎▎▎▎▎▎▎▎▎▎▎▎▎▎▎▎▎▎▎▎▎▎▎▎▎▎▎▎▎▎▎▎▎▎▎▎▎▎} {▎ ▎} {▎ 大 ...
随机推荐
- 【转】一些 SQLite技巧
部分来源于网络 SQLite 删除重复行 需求:现存在一张表tender_to_detailedlist,然后里面的列tender_id和detailedlist_id具有相同的数据且不确定相同数据的 ...
- 在VS中用正则表达式查找或替换
2005VS和2008VS正则替换规则如下(2013VS不适合,不需要的同学可以直接跳到2013VS的操作办法): Example: 查找#incldue中带有gl开头的头文件的,用include.+ ...
- maven-各配置文件详解
1.setting.xml http://www.cnblogs.com/yangxia-test/p/4409736.html <?xml version="1.0" en ...
- 【USACO 2.4】Cow Tours (最短路)
题意:给你n(最多150)个点的坐标,给出邻接矩阵,并且整个图至少两个联通块,现在让你连接一条边,使得所有可联通的两点的最短距离的最大值最小. 题解:先dfs染色,再用floyd跑出原图的直径O($n ...
- Ubuntu/Mint更换阿里云源
sudo cp /etc/apt/sources.list /etc/apt/sources.list.bak #备份 sudo vim /etc/apt/sources.list #修改 sudo ...
- transform
{ transform: scale3d(x,y,z) /*放大*/ translate3d(x,y,z) /*位置*/ rotate3d(x,y,z,angle) /*旋转*/ skew(x-ang ...
- 通过jquery的serializearray处理表单数据成json格式,并提交到后台处理
var params = $("#myform").serializeArray(); var values = {}; for (var item in params) { va ...
- Linux硬链接和软链接
1.Linux链接概念Linux链接分两种,一种被称为硬链接(Hard Link),另一种被称为符号链接(Symbolic Link).默认情况下,ln命令产生硬链接. [硬连接]硬连接指通过索引节点 ...
- LoadRunner 函数之lr_xml_get_values
简单实例如 char *xml_input = "<?xml version=\"1.0\" encoding=\"UTF-8\"?>&q ...
- [NHibernate]视图处理
目录 写在前面 文档与系列文章 视图 一个例子 总结 写在前面 前面的文章主要讲了对物理数据表的操作,当然了Nhibernate同样可以操作视图,本文将讲nhibernate对视图操作的种种. 文档与 ...