unit Unit1;interfaceuses
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
Dialogs, StdCtrls;type
TForm1 = class(TForm)
Edit1: TEdit;
Button1: TButton;
Label1: TLabel;
Label2: TLabel;
procedure Button1Click(Sender: TObject);
private
{ Private declarations }
public
{ Public declarations }
end;var
Form1: TForm1;implementation{$R *.dfm}procedure TForm1.Button1Click(Sender: TObject);
type
tvowels=set of char;
var
vowels:tvowels;
begin
vowels:=['a','e','i','o','u'];
if edit1.text[1] in vowels then
lable2.Caption:='是元音';
else
lable2.Caption:='请再试';
end;end.
解决方案 »
- 想做一个票据打印程序,请大家给个思路
- 新人,第一次接触delphi,望各位给点最基本的语法书籍,谢谢!
- 开发的软件使用SQLServer2000数据库,打包时能让数据库、数据文件自动安装么?(全自动安装)
- 在DBGrid中,如何判断焦点移动到了另一行?
- c/s结构应用中,不装oracle client,如何访问数据库服务器
- 如何给 quickreport 加上背景图片
- 类中如何捕捉更详细的错误信息(在线等待!)
- zcvz
- Delphi中有没有"Proxies.pas"这个文件。
- 请goalitaly(迈克尔.朱珠) 、Kronus(Kronus) 、myyanghua(水手)进来领分
- 关于TStringList的用法?
- 高分相送一道推理题:知道答案的人将是一个优秀的程序员(题目很短)
这几句报错,请大家指导一下,
type
tvowels=set of char;
var
vowels:tvowels;
begin
vowels:=['a','e','i','o','u'];
if edit1.text[1] in vowels then
lable2.Caption:='是元音'
else
lable2.Caption:='请再试';
end;
type
tvowels=set of char;
var
vowels:tvowels;
begin
vowels:=['a','e','i','o','u'];
if edit1.text[1] in vowels then
label2.Caption:='是元音'
else
label2.Caption:='请再试';
end;