delphi Sender和Tag的用法1


unit Unit1;
interface
uses
Winapi.Windows, Winapi.Messages,
System.SysUtils, System.Variants, System.Classes,
Vcl.Graphics,
Vcl.Controls, Vcl.Forms, Vcl.Dialogs,
Vcl.StdCtrls;
type
TForm1 = class(TForm)
Button1:
TButton;
Button2:
TButton;
Button3:
TButton;
Button4:
TButton;
Button5:
TButton;
Button6:
TButton;
Button7:
TButton;
procedure
Button1Click(Sender: TObject);
private
{ Private declarations }
public
{ Public declarations }
end;
var
Form1: TForm1;
implementation
{$R
*.dfm}
procedure
TForm1.Button1Click(Sender: TObject);
begin
if Sender is
TButton then
ShowMessage((Sender
as TButton).Caption);
end;
delphi Sender和Tag的用法1的更多相关文章
- delphi Sender和Tag的用法
var Form1: TForm1; SelectedColor:TColor;//clBlack; //Defaultimplementation{$R *.dfm}procedure TFor ...
- Delphi中 StrToIntDef函数的用法
Delphi中 StrToIntDef函数的用法:比如我要判断一个文本框里输入的字符串能不能转换为integer类型,如果能,则返回转换后的整型数据,如果不能,则返回整数0,那么我就可以用strtoi ...
- delphi中Application.MessageBox函数用法详解
delphi中Application.MessageBox函数用法详解 Application.MessageBox是TApplication的成员函数,声明如下:functionTApplicati ...
- Delphi中 TStringList 的详细用法 good
TStringList 类是在Delphi使用最厂的一个对像,我们这里一起来看看 TStringList 的详细用法. 先把要讨论的几个属性列出来:1.CommaText2.Delimiter &am ...
- Delphi 预编译指令 的用法
A.3 使用条件编译指令条件编译指令是非常重要的编译指令,他控制着在不同条件下(例如,不同的操作系统)产生不同的代码.条件编译指令是包含在注释括号之内的,如下表所示. ...
- Delphi线程定时器TThreadedTimer及用法--还有TThreadList用法可以locklist
Delphi线程定时器 - -人生如歌- - 博客园http://www.cnblogs.com/zhengwei0113/p/4192010.html (* 自己编写的线程计时器,没有采用消息机制, ...
- Delphi StringGrid控件的用法
Delphi StringGrid控件 组件名称:StringGrid ●固定行及固定列: StringGrid.FixedCols:=固定行之数; StringGrid.Fixe ...
- delphi 10.2 ---treeview 基本用法
unit Unit2; interface uses Winapi.Windows, Winapi.Messages, System.SysUtils, System.Variants, System ...
- Delphi Format函数功能及用法详解
DELPHI中Format函数功能及用法详解 DELPHI中Format函数功能及用法详解function Format(const Format: string; const Args: array ...
随机推荐
- cgroup隔离的知识点
tasks中写入的是线程号 cgroup.procs是进程号 ===================CPU隔离===================== 主机CPU核数: cat /proc/cpui ...
- strcpy函数和strncpy函数的区别
strcpy函数和strncpy函数的原型介绍在我的另一篇文章中介绍了,见strcpy,strncpy,strlen等函数原型 strcpy:字串复制 原型:char *strcpy(char *de ...
- ASIHttpRequest 使用过程中,中文编码的问题
遇到过几个中文编码的情况,不知道是服务器原因还是本身方法上有区别 ,今天遇到的问题是使用1的方法行不通,但是使用2的方法就可以. 1. NSString *urlString= [NSString s ...
- The Automated Testing Handbook 自动化测试手册简介
Learn what works, what doesn't and why. The Automated Testing Handbook is a practical blueprint for ...
- ASP.NET将word文档转换成pdf的代码
一.添加引用 using Microsoft.Office.Interop.Word; 二.转换方法 1.方法 C# 代码 /// <summary> /// 把Word文件转换成pdf文 ...
- 【跟我一起学Python吧】Python 多线程
其实自我感觉Python的多线程很类似于Java的多线程机制,但是比JAVA的多线程更灵活.在早期的Python多线程实现中,采用了thread模块.例如: from time import ctim ...
- HDU-4749 Parade Show KMP算法 | DP
题目链接:http://acm.hdu.edu.cn/showproblem.php?pid=4749 题意:给两个串S和P,求S串中存在多少个与P串的大小关系一样的串. 因为数字的范围是1<= ...
- Linux Oracle服务启动&停止脚本与开机自启动
在CentOS 6.3下安装完Oracle 10g R2,重开机之后,你会发现Oracle没有自行启动,这是正常的,因为在Linux下安装Oracle的确不会自行启动,必须要自行设定相关参数,首先先介 ...
- angularjs ng-class 两种用法
ng-class="{'active':current.actived_tree==item}" ng-class="{true:'label-danger white- ...
- CSS 去掉IE10中type=password中的眼睛图标
在IE10中,input[type=password],如果我们输入内容后,内容会变成圆点,这与以前一样,但后面多了一个眼睛图标,我们鼠标移过去按下会出现输入内容.有时我们想去掉这功能.IE10允许我 ...