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


本文整理自网络,侵删。

 如何判断剪切板中中的内容的类型,是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 is1251char

Delphi xe tbitmap支持gif,成为具有jpg,gif,bmp,ico,gif五种显示功能的图片控件

Delphi settextbuf

Delphi record,两种声明方式

Delphi 时间转成大写

Delphi把一个字符串中的某个子串,用另一个子串去替换

Delphi 在 api 函数中使用 pchar 参数的几种方法

Delphi webbrowser 表单赋值模拟点击

Delphi 创建文件夹并打开

Delphi 利用sendinput模拟鼠标键盘

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



打赏

取消

感谢您的支持,我会继续努力的!

扫码支持
扫码打赏,您说多少就多少

打开支付宝扫一扫,即可进行扫码打赏哦

分享从这里开始,精彩与您同在

评论

管理员已关闭评论功能...