if Query2.RecordCount<>0 then
begin
if application.MessageBox('a','注意!',Mb_YesNoCancel + Mb_IconQuestion)=Id_Yes then
begin
strpcopy(CMPP_SUBMIT_tag.FeeType,'01');
strpcopy(CMPP_SUBMIT_tag.FeeCode,'000');
end
else
exit;
end
else
begin
if application.MessageBox('b','注意!',Mb_YesNoCancel + Mb_IconQuestion)=Id_Yes then
begin
strpcopy(CMPP_SUBMIT_tag.FeeType,'02');
strpcopy(CMPP_SUBMIT_tag.FeeCode,'100');
end
else
exit;
end;
上面这段代码在编译时出现以下错误:
[Error] main.pas(288): Illegal character in input file: ' ' ($A1A1)
是什么原因?
begin
if application.MessageBox('a','注意!',Mb_YesNoCancel + Mb_IconQuestion)=Id_Yes then
begin
strpcopy(CMPP_SUBMIT_tag.FeeType,'01');
strpcopy(CMPP_SUBMIT_tag.FeeCode,'000');
end
else
exit;
end
else
begin
if application.MessageBox('b','注意!',Mb_YesNoCancel + Mb_IconQuestion)=Id_Yes then
begin
strpcopy(CMPP_SUBMIT_tag.FeeType,'02');
strpcopy(CMPP_SUBMIT_tag.FeeCode,'100');
end
else
exit;
end;
上面这段代码在编译时出现以下错误:
[Error] main.pas(288): Illegal character in input file: ' ' ($A1A1)
是什么原因?
出错的地方在:
if application.MessageBox('b','注意!',Mb_YesNoCancel + Mb_IconQuestion)=Id_Yes then的下面一行.
即begin
Thanks!
CMPP_SUBMIT_tag.FeeType, ...
的類型不對, 你看是不是 pchar 類型的!
begin
strpcopy(CMPP_SUBMIT_tag.FeeType,'01');
strpcopy(CMPP_SUBMIT_tag.FeeCode,'000');
又没有错,编译正确呢?
Illegal character in input file: ' ' ($A1A1)
就是在本句的前面或后面有不可见的空格,可能不是英文状态输入的,一般是直接Copy代码造成的,你把出问题的一行和前后行都整行删除掉,重新写