|

楼主 |
发表于 2019-3-28 14:26:54
|
显示全部楼层
谢谢楼上指点。但我运行后还是报错见图:- TForm1.RadioButton1Click(Sender: TObject); //选择性别
- begin
- if radiobutton1.checked then
- str_sex:='男';
- end
- else if radiobutton2.checked then
- begin
- str_sex:='女';
- end;
- end;
- end.
复制代码
出错信息如下:
构建
[错误] Unit1.pas(51): ';' expected but 'ELSE' found
[错误] Unit1.pas(55): '.' expected but 'END' found
[错误] Unit1.pas(29): Unsatisfied forward or external declaration: 'TForm1.RadioGroup1Click'
[错误] Unit1.pas(30): Unsatisfied forward or external declaration: 'TForm1.CheckBox1Click'
[错误] Unit1.pas(31): Unsatisfied forward or external declaration: 'TForm1.Button1Click'
[致命错误] Project1.dpr(5): Could not compile used unit 'Unit1.pas'
|
|