while not eof do这个应该指定是 while not table1.eof do begin
while not eof do begin if table1.FieldByName('日期').asdatetime-strtodatetime(trim(edit3.text))>0 then break;//如果条件是真,那么Table1怎么向下移,其他同楼上
BS(): if table1.FieldByName('日期').asdatetime-strtodatetime(trim(edit3.text))>0 then break;//如果条件为真,则结束循环呀 delphi0302(好好学习,天天向上!) : while not table1.eof do begin //这么加了后还是不行呀
BS(): 若是whlie not eof do begin 则有如下错误:Project Project1.exe raised exception class EInOutError with message 'I/O error104'. Process stoped. use step or Run to contunue. 若是while table1.eof do begin 则有如下错误: Project Project1.exe raised exception class EDatabaseError with message 'Table1:Dataset not in edit or insert mode'.Process stoped. use step or Run to contunue. 为什么要Table1处在编辑或插入状态?我只是读取数据呀!还有。我用的是私有变量。在这个单元中还有别有函数要用到。
while not table1.eof do begin
begin
if table1.FieldByName('日期').asdatetime-strtodatetime(trim(edit3.text))>0 then
break;//如果条件是真,那么Table1怎么向下移,其他同楼上
if table1.FieldByName('日期').asdatetime-strtodatetime(trim(edit3.text))>0 then
break;//如果条件为真,则结束循环呀 delphi0302(好好学习,天天向上!) :
while not table1.eof do begin
//这么加了后还是不行呀
另外,你用到的变量都是全局变量吗?是不是有点浪费
若是whlie not eof do begin
则有如下错误:Project Project1.exe raised exception class EInOutError with message 'I/O error104'. Process stoped. use step or Run to contunue.
若是while table1.eof do begin
则有如下错误:
Project Project1.exe raised exception class EDatabaseError with message 'Table1:Dataset not in edit or insert mode'.Process stoped. use step or Run to contunue.
为什么要Table1处在编辑或插入状态?我只是读取数据呀!还有。我用的是私有变量。在这个单元中还有别有函数要用到。
你在打开表之后加上一个table。open 试试。如果通过则是你不注意可能写表了!
你的table1变量是全局的还是局部的?你可以单步跟一下程序,看在哪个地方出错,应该不是大问题的。