Delphi 如何判断Clipboard剪切板中的内容的类型

2022-10-20 16:24:35 作者:admin

本文整理自网络,侵删。

 如何判断剪切板中中的内容的类型,是image 是text 是wav 
Some   of   the   possible   values   of   the   Format   parameter   follow.   HasFormat   supports   additional   formats   provided   by   Windows   or   by   other   applications   as   well   as   custom   formats   registered   with   TPicture.RegisterCliPBoardFormat.  
   
Value Meaning  
   
CF_TEXT Text   wITh   a   CR-LF   combination   at   the   end   of   each   line.   A   null   character   identifies   the   end   of   the   text.  
CF_BITMAP A   Windows   bITmap   graphic.  
CF_METAFILEPICT A   Windows   metafile   graphic.  
CF_PICTURE An   object   of   type   TPicture.  
CF_COMPONENT Any   persistent   object.   
    

procedure   TForm1.Button1Click(Sender:   TObject);   
begin  
if   CliPBoard.HasFormat(CF_TEXT)   then  
      EdIT1.Text   :=   CliPBoard.AsText  

相关阅读 >>

Delphi 过卡巴2009和沙盘启发杀毒的Delphi源代码

关于如何发现Delphi程序的内存泄漏

Delphi stringgrid 实例3: 本例功能: 1、修改 tstringgrid的默认宽与高; 2、添加行; 3、确认当前单元并赋值.

Delphi 解决timage无法在窗体resize时改变canvas的大小

Delphi ascii 码对照表

Delphi xe string与tstringbuilder的关系

Delphi tnethttpclient https忽略证书验证

Delphi连接access提示密码无效解决一例

Delphi controls 属性与继承 tshape 类的小练习

Delphi 数组类型与数组指针的巧妙利用

更多相关阅读请进入《Delphi》频道 >>



在线咨询 拨打电话