过滤条件埴Table1.Filter属性框可运行,但放按钮里不行错哪了?
delphi吧
全部回复
仅看楼主
level 1
长虹64 楼主
将 难度系数=2 and 题号 > 10 过滤条件 直接填在Table1.Filter属性框里可以运行,但将其移到按钮里
procedure TForm1.Button2Click(Sender: TObject);
begin
Table1.Filter:=难度系数=2 and 题号 > 10;
table1.filtered:=true;
end;
再编译时就会出错了。
[错误] Unit1.pas(45): Illegal character in input file: *难* ($C4D1)
[错误] Unit1.pas(45): Illegal character in input file: *题* ($CCE2)
[致命错误] Project1.dpr(5): Could not compile used unit *Unit1.pas*
2014年08月17日 13点08分 1
level 12
and两边的判断条件加括号试试
2014年08月18日 00点08分 2
看清楚,人家的问题。这种问题的标准答案是:看书去。
2014年08月18日 01点08分
level 10
看书去
书都没看,就不要出来丢人现眼了。
2014年08月18日 01点08分 3
楼主应该不是专业编程的,所以......
2014年08月18日 11点08分
吧务
level 14
字符串要加引号
2014年08月18日 11点08分 4
就是这个问题谢,开始我以为是数据类型不对
2014年08月19日 13点08分
1